storybook-addon-playwright 4.9.0 → 4.9.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.
@@ -579,7 +579,8 @@
579
579
  "type": "Promise",
580
580
  "parameters": {
581
581
  "selector": {
582
- "type": "string"
582
+ "type": "string",
583
+ "description": "A selector to query for. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
583
584
  },
584
585
  "options": {
585
586
  "type": "object",
@@ -594,9 +595,13 @@
594
595
  ],
595
596
  "description": "Defaults to `'visible'`. Can be either:\n- `'attached'` - wait for element to be present in DOM.\n- `'detached'` - wait for element to not be present in DOM.\n- `'visible'` - wait for element to have non-empty bounding box and no `visibility:hidden`. Note that element without\n any content or with `display:none` has an empty bounding box and is not considered visible.\n- `'hidden'` - wait for element to be either detached from DOM, or have an empty bounding box or `visibility:hidden`.\n This is opposite to the `'visible'` option."
596
597
  },
598
+ "strict": {
599
+ "type": "boolean",
600
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
601
+ },
597
602
  "timeout": {
598
603
  "type": "number",
599
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
604
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
600
605
  }
601
606
  },
602
607
  "additionalProperties": false
@@ -606,7 +611,7 @@
606
611
  "selector",
607
612
  "options"
608
613
  ],
609
- "description": "Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or\n`detached`.\n\nWait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If at\nthe moment of calling the method `selector` already satisfies the condition, the method will return immediately. If the\nselector doesn't satisfy the condition for the `timeout` milliseconds, the function will throw.\n\nThis method works across navigations:\n\n```js\nconst { chromium } = require('playwright'); // Or 'firefox' or 'webkit'.\n\n(async () => {\n const browser = await chromium.launch();\n const page = await browser.newPage();\n for (let currentURL of ['https://google.com', 'https://bbc.com']) {\n await page.goto(currentURL);\n const element = await page.waitForSelector('img');\n console.log('Loaded image: ' + await element.getAttribute('src'));\n }\n await browser.close();\n})();\n```"
614
+ "description": "Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or\n`detached`.\n\nWait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If at\nthe moment of calling the method `selector` already satisfies the condition, the method will return immediately. If the\nselector doesn't satisfy the condition for the `timeout` milliseconds, the function will throw.\n\nThis method works across navigations:\n\n```js\nconst { chromium } = require('playwright'); // Or 'firefox' or 'webkit'.\n\n(async () => {\n const browser = await chromium.launch();\n const page = await browser.newPage();\n for (let currentURL of ['https://google.com', 'https://bbc.com']) {\n await page.goto(currentURL);\n const element = await page.waitForSelector('img');\n console.log('Loaded image: ' + await element.getAttribute('src'));\n }\n await browser.close();\n})();\n``` \n Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or\n`detached`.\n\nWait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If at\nthe moment of calling the method `selector` already satisfies the condition, the method will return immediately. If the\nselector doesn't satisfy the condition for the `timeout` milliseconds, the function will throw.\n\nThis method works across navigations:\n\n```js\nconst { chromium } = require('playwright'); // Or 'firefox' or 'webkit'.\n\n(async () => {\n const browser = await chromium.launch();\n const page = await browser.newPage();\n for (let currentURL of ['https://google.com', 'https://bbc.com']) {\n await page.goto(currentURL);\n const element = await page.waitForSelector('img');\n console.log('Loaded image: ' + await element.getAttribute('src'));\n }\n await browser.close();\n})();\n``` \n Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or\n`detached`.\n\nWait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If at\nthe moment of calling the method `selector` already satisfies the condition, the method will return immediately. If the\nselector doesn't satisfy the condition for the `timeout` milliseconds, the function will throw.\n\nThis method works across navigations:\n\n```js\nconst { chromium } = require('playwright'); // Or 'firefox' or 'webkit'.\n\n(async () => {\n const browser = await chromium.launch();\n const page = await browser.newPage();\n for (let currentURL of ['https://google.com', 'https://bbc.com']) {\n await page.goto(currentURL);\n const element = await page.waitForSelector('img');\n console.log('Loaded image: ' + await element.getAttribute('src'));\n }\n await browser.close();\n})();\n``` \n Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or\n`detached`.\n\nWait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If at\nthe moment of calling the method `selector` already satisfies the condition, the method will return immediately. If the\nselector doesn't satisfy the condition for the `timeout` milliseconds, the function will throw.\n\nThis method works across navigations:\n\n```js\nconst { chromium } = require('playwright'); // Or 'firefox' or 'webkit'.\n\n(async () => {\n const browser = await chromium.launch();\n const page = await browser.newPage();\n for (let currentURL of ['https://google.com', 'https://bbc.com']) {\n await page.goto(currentURL);\n const element = await page.waitForSelector('img');\n console.log('Loaded image: ' + await element.getAttribute('src'));\n }\n await browser.close();\n})();\n```"
610
615
  },
611
616
  "check": {
612
617
  "kind": "function",
@@ -614,7 +619,7 @@
614
619
  "parameters": {
615
620
  "selector": {
616
621
  "type": "string",
617
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
622
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
618
623
  },
619
624
  "options": {
620
625
  "type": "object",
@@ -627,9 +632,34 @@
627
632
  "type": "boolean",
628
633
  "description": "Actions that initiate navigations are waiting for these navigations to happen and for pages to start loading. You can\nopt out of waiting via setting this flag. You would only need this option in the exceptional cases such as navigating to\ninaccessible pages. Defaults to `false`."
629
634
  },
635
+ "position": {
636
+ "type": "object",
637
+ "properties": {
638
+ "x": {
639
+ "type": "number"
640
+ },
641
+ "y": {
642
+ "type": "number"
643
+ }
644
+ },
645
+ "required": [
646
+ "x",
647
+ "y"
648
+ ],
649
+ "additionalProperties": false,
650
+ "description": "A point to use relative to the top-left corner of element padding box. If not specified, uses some visible point of the\nelement."
651
+ },
652
+ "strict": {
653
+ "type": "boolean",
654
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
655
+ },
630
656
  "timeout": {
631
657
  "type": "number",
632
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
658
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
659
+ },
660
+ "trial": {
661
+ "type": "boolean",
662
+ "description": "When set, this method only performs the [actionability](https://playwright.dev/docs/actionability) checks and skips the action. Defaults to\n`false`. Useful to wait until the element is ready for the action without performing it."
633
663
  }
634
664
  },
635
665
  "additionalProperties": false
@@ -638,7 +668,7 @@
638
668
  "required": [
639
669
  "selector"
640
670
  ],
641
- "description": "This method checks an element matching `selector` by performing the following steps:\n1. Find an element match matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Ensure that matched element is a checkbox or a radio input. If not, this method rejects. If the element is already\n checked, this method returns immediately.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#pagemouse) to click in the center of the element.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n1. Ensure that the element is now checked. If not, this method rejects.\n\nWhen all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError].\nPassing zero timeout disables this.\n\nShortcut for main frame's\n[frame.check(selector[, options])](https://playwright.dev/docs/api/class-frame#framecheckselector-options)."
671
+ "description": "This method checks an element matching `selector` by performing the following steps:\n1. Find an element matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Ensure that matched element is a checkbox or a radio input. If not, this method throws. If the element is already\n checked, this method returns immediately.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#page-mouse) to click in the center of the element.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n1. Ensure that the element is now checked. If not, this method throws.\n\nWhen all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing\nzero timeout disables this.\n\nShortcut for main frame's [frame.check(selector[, options])](https://playwright.dev/docs/api/class-frame#frame-check)."
642
672
  },
643
673
  "click": {
644
674
  "kind": "function",
@@ -646,7 +676,7 @@
646
676
  "parameters": {
647
677
  "selector": {
648
678
  "type": "string",
649
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
679
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
650
680
  },
651
681
  "options": {
652
682
  "type": "object",
@@ -706,9 +736,17 @@
706
736
  "additionalProperties": false,
707
737
  "description": "A point to use relative to the top-left corner of element padding box. If not specified, uses some visible point of the\nelement."
708
738
  },
739
+ "strict": {
740
+ "type": "boolean",
741
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
742
+ },
709
743
  "timeout": {
710
744
  "type": "number",
711
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
745
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
746
+ },
747
+ "trial": {
748
+ "type": "boolean",
749
+ "description": "When set, this method only performs the [actionability](https://playwright.dev/docs/actionability) checks and skips the action. Defaults to\n`false`. Useful to wait until the element is ready for the action without performing it."
712
750
  }
713
751
  },
714
752
  "additionalProperties": false
@@ -717,7 +755,7 @@
717
755
  "required": [
718
756
  "selector"
719
757
  ],
720
- "description": "This method clicks an element matching `selector` by performing the following steps:\n1. Find an element match matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#pagemouse) to click in the center of the element, or\n the specified `position`.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n\nWhen all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError].\nPassing zero timeout disables this.\n\nShortcut for main frame's\n[frame.click(selector[, options])](https://playwright.dev/docs/api/class-frame#frameclickselector-options)."
758
+ "description": "This method clicks an element matching `selector` by performing the following steps:\n1. Find an element matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#page-mouse) to click in the center of the element, or\n the specified `position`.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n\nWhen all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing\nzero timeout disables this.\n\nShortcut for main frame's [frame.click(selector[, options])](https://playwright.dev/docs/api/class-frame#frame-click)."
721
759
  },
722
760
  "dblclick": {
723
761
  "kind": "function",
@@ -725,7 +763,7 @@
725
763
  "parameters": {
726
764
  "selector": {
727
765
  "type": "string",
728
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
766
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
729
767
  },
730
768
  "options": {
731
769
  "type": "object",
@@ -781,9 +819,17 @@
781
819
  "additionalProperties": false,
782
820
  "description": "A point to use relative to the top-left corner of element padding box. If not specified, uses some visible point of the\nelement."
783
821
  },
822
+ "strict": {
823
+ "type": "boolean",
824
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
825
+ },
784
826
  "timeout": {
785
827
  "type": "number",
786
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
828
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
829
+ },
830
+ "trial": {
831
+ "type": "boolean",
832
+ "description": "When set, this method only performs the [actionability](https://playwright.dev/docs/actionability) checks and skips the action. Defaults to\n`false`. Useful to wait until the element is ready for the action without performing it."
787
833
  }
788
834
  },
789
835
  "additionalProperties": false
@@ -792,7 +838,7 @@
792
838
  "required": [
793
839
  "selector"
794
840
  ],
795
- "description": "This method double clicks an element matching `selector` by performing the following steps:\n1. Find an element match matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#pagemouse) to double click in the center of the\n element, or the specified `position`.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. Note that if the\n first click of the `dblclick()` triggers a navigation event, this method will reject.\n\nWhen all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError].\nPassing zero timeout disables this.\n\n> NOTE: `page.dblclick()` dispatches two `click` events and a single `dblclick` event.\n\nShortcut for main frame's\n[frame.dblclick(selector[, options])](https://playwright.dev/docs/api/class-frame#framedblclickselector-options)."
841
+ "description": "This method double clicks an element matching `selector` by performing the following steps:\n1. Find an element matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#page-mouse) to double click in the center of the\n element, or the specified `position`.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. Note that if the\n first click of the `dblclick()` triggers a navigation event, this method will throw.\n\nWhen all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing\nzero timeout disables this.\n\n> NOTE: `page.dblclick()` dispatches two `click` events and a single `dblclick` event.\n\nShortcut for main frame's\n[frame.dblclick(selector[, options])](https://playwright.dev/docs/api/class-frame#frame-dblclick)."
796
842
  },
797
843
  "fill": {
798
844
  "kind": "function",
@@ -800,7 +846,7 @@
800
846
  "parameters": {
801
847
  "selector": {
802
848
  "type": "string",
803
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
849
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
804
850
  },
805
851
  "value": {
806
852
  "type": "string",
@@ -809,13 +855,21 @@
809
855
  "options": {
810
856
  "type": "object",
811
857
  "properties": {
858
+ "force": {
859
+ "type": "boolean",
860
+ "description": "Whether to bypass the [actionability](https://playwright.dev/docs/actionability) checks. Defaults to `false`."
861
+ },
812
862
  "noWaitAfter": {
813
863
  "type": "boolean",
814
864
  "description": "Actions that initiate navigations are waiting for these navigations to happen and for pages to start loading. You can\nopt out of waiting via setting this flag. You would only need this option in the exceptional cases such as navigating to\ninaccessible pages. Defaults to `false`."
815
865
  },
866
+ "strict": {
867
+ "type": "boolean",
868
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
869
+ },
816
870
  "timeout": {
817
871
  "type": "number",
818
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
872
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
819
873
  }
820
874
  },
821
875
  "additionalProperties": false
@@ -825,7 +879,7 @@
825
879
  "selector",
826
880
  "value"
827
881
  ],
828
- "description": "This method waits for an element matching `selector`, waits for [actionability](https://playwright.dev/docs/actionability) checks, focuses the\nelement, fills it and triggers an `input` event after filling. If the element is inside the `<label>` element that has\nassociated [control](https://developer.mozilla.org/en-US/docs/Web/API/HTMLLabelElement/control), that control will be\nfilled instead. If the element to be filled is not an `<input>`, `<textarea>` or `[contenteditable]` element, this\nmethod throws an error. Note that you can pass an empty string to clear the input field.\n\nTo send fine-grained keyboard events, use\n[page.type(selector, text[, options])](https://playwright.dev/docs/api/class-page#pagetypeselector-text-options).\n\nShortcut for main frame's\n[frame.fill(selector, value[, options])](https://playwright.dev/docs/api/class-frame#framefillselector-value-options)"
882
+ "description": "This method waits for an element matching `selector`, waits for [actionability](https://playwright.dev/docs/actionability) checks, focuses the\nelement, fills it and triggers an `input` event after filling. Note that you can pass an empty string to clear the input\nfield.\n\nIf the target element is not an `<input>`, `<textarea>` or `[contenteditable]` element, this method throws an error.\nHowever, if the element is inside the `<label>` element that has an associated\n[control](https://developer.mozilla.org/en-US/docs/Web/API/HTMLLabelElement/control), the control will be filled\ninstead.\n\nTo send fine-grained keyboard events, use\n[page.type(selector, text[, options])](https://playwright.dev/docs/api/class-page#page-type).\n\nShortcut for main frame's\n[frame.fill(selector, value[, options])](https://playwright.dev/docs/api/class-frame#frame-fill)."
829
883
  },
830
884
  "focus": {
831
885
  "kind": "function",
@@ -833,14 +887,18 @@
833
887
  "parameters": {
834
888
  "selector": {
835
889
  "type": "string",
836
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
890
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
837
891
  },
838
892
  "options": {
839
893
  "type": "object",
840
894
  "properties": {
895
+ "strict": {
896
+ "type": "boolean",
897
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
898
+ },
841
899
  "timeout": {
842
900
  "type": "number",
843
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
901
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
844
902
  }
845
903
  },
846
904
  "additionalProperties": false
@@ -849,7 +907,7 @@
849
907
  "required": [
850
908
  "selector"
851
909
  ],
852
- "description": "This method fetches an element with `selector` and focuses it. If there's no element matching `selector`, the method\nwaits until a matching element appears in the DOM.\n\nShortcut for main frame's\n[frame.focus(selector[, options])](https://playwright.dev/docs/api/class-frame#framefocusselector-options)."
910
+ "description": "This method fetches an element with `selector` and focuses it. If there's no element matching `selector`, the method\nwaits until a matching element appears in the DOM.\n\nShortcut for main frame's [frame.focus(selector[, options])](https://playwright.dev/docs/api/class-frame#frame-focus)."
853
911
  },
854
912
  "hover": {
855
913
  "kind": "function",
@@ -857,7 +915,7 @@
857
915
  "parameters": {
858
916
  "selector": {
859
917
  "type": "string",
860
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
918
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
861
919
  },
862
920
  "options": {
863
921
  "type": "object",
@@ -896,9 +954,17 @@
896
954
  "additionalProperties": false,
897
955
  "description": "A point to use relative to the top-left corner of element padding box. If not specified, uses some visible point of the\nelement."
898
956
  },
957
+ "strict": {
958
+ "type": "boolean",
959
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
960
+ },
899
961
  "timeout": {
900
962
  "type": "number",
901
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
963
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
964
+ },
965
+ "trial": {
966
+ "type": "boolean",
967
+ "description": "When set, this method only performs the [actionability](https://playwright.dev/docs/actionability) checks and skips the action. Defaults to\n`false`. Useful to wait until the element is ready for the action without performing it."
902
968
  }
903
969
  },
904
970
  "additionalProperties": false
@@ -907,7 +973,7 @@
907
973
  "required": [
908
974
  "selector"
909
975
  ],
910
- "description": "This method hovers over an element matching `selector` by performing the following steps:\n1. Find an element match matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#pagemouse) to hover over the center of the element, or\n the specified `position`.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n\nWhen all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError].\nPassing zero timeout disables this.\n\nShortcut for main frame's\n[frame.hover(selector[, options])](https://playwright.dev/docs/api/class-frame#framehoverselector-options)."
976
+ "description": "This method hovers over an element matching `selector` by performing the following steps:\n1. Find an element matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#page-mouse) to hover over the center of the element,\n or the specified `position`.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n\nWhen all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing\nzero timeout disables this.\n\nShortcut for main frame's [frame.hover(selector[, options])](https://playwright.dev/docs/api/class-frame#frame-hover)."
911
977
  },
912
978
  "keyboard": {
913
979
  "type": "object",
@@ -924,7 +990,7 @@
924
990
  "required": [
925
991
  "key"
926
992
  ],
927
- "description": "Dispatches a `keydown` event.\n\n`key` can specify the intended [keyboardEvent.key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key)\nvalue or a single character to generate the text for. A superset of the `key` values can be found\n[here](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values). Examples of the keys are:\n\n`F1` - `F12`, `Digit0`- `Digit9`, `KeyA`- `KeyZ`, `Backquote`, `Minus`, `Equal`, `Backslash`, `Backspace`, `Tab`,\n`Delete`, `Escape`, `ArrowDown`, `End`, `Enter`, `Home`, `Insert`, `PageDown`, `PageUp`, `ArrowRight`, `ArrowUp`, etc.\n\nFollowing modification shortcuts are also supported: `Shift`, `Control`, `Alt`, `Meta`, `ShiftLeft`.\n\nHolding down `Shift` will type the text that corresponds to the `key` in the upper case.\n\nIf `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective\ntexts.\n\nIf `key` is a modifier key, `Shift`, `Meta`, `Control`, or `Alt`, subsequent key presses will be sent with that modifier\nactive. To release the modifier key, use\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboardupkey).\n\nAfter the key is pressed once, subsequent calls to\n[keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboarddownkey) will have\n[repeat](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/repeat) set to true. To release the key, use\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboardupkey).\n\n> NOTE: Modifier keys DO influence `keyboard.down`. Holding down `Shift` will type the text in upper case."
993
+ "description": "Dispatches a `keydown` event.\n\n`key` can specify the intended [keyboardEvent.key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key)\nvalue or a single character to generate the text for. A superset of the `key` values can be found\n[here](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values). Examples of the keys are:\n\n`F1` - `F12`, `Digit0`- `Digit9`, `KeyA`- `KeyZ`, `Backquote`, `Minus`, `Equal`, `Backslash`, `Backspace`, `Tab`,\n`Delete`, `Escape`, `ArrowDown`, `End`, `Enter`, `Home`, `Insert`, `PageDown`, `PageUp`, `ArrowRight`, `ArrowUp`, etc.\n\nFollowing modification shortcuts are also supported: `Shift`, `Control`, `Alt`, `Meta`, `ShiftLeft`.\n\nHolding down `Shift` will type the text that corresponds to the `key` in the upper case.\n\nIf `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective\ntexts.\n\nIf `key` is a modifier key, `Shift`, `Meta`, `Control`, or `Alt`, subsequent key presses will be sent with that modifier\nactive. To release the modifier key, use [keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-up).\n\nAfter the key is pressed once, subsequent calls to\n[keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-down) will have\n[repeat](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/repeat) set to true. To release the key, use\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-up).\n\n> NOTE: Modifier keys DO influence `keyboard.down`. Holding down `Shift` will type the text in upper case."
928
994
  },
929
995
  "insertText": {
930
996
  "kind": "function",
@@ -962,7 +1028,7 @@
962
1028
  "required": [
963
1029
  "key"
964
1030
  ],
965
- "description": "`key` can specify the intended [keyboardEvent.key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key)\nvalue or a single character to generate the text for. A superset of the `key` values can be found\n[here](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values). Examples of the keys are:\n\n`F1` - `F12`, `Digit0`- `Digit9`, `KeyA`- `KeyZ`, `Backquote`, `Minus`, `Equal`, `Backslash`, `Backspace`, `Tab`,\n`Delete`, `Escape`, `ArrowDown`, `End`, `Enter`, `Home`, `Insert`, `PageDown`, `PageUp`, `ArrowRight`, `ArrowUp`, etc.\n\nFollowing modification shortcuts are also supported: `Shift`, `Control`, `Alt`, `Meta`, `ShiftLeft`.\n\nHolding down `Shift` will type the text that corresponds to the `key` in the upper case.\n\nIf `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective\ntexts.\n\nShortcuts such as `key: \"Control+o\"` or `key: \"Control+Shift+T\"` are supported as well. When speficied with the\nmodifier, modifier is pressed and being held while the subsequent key is being pressed.\n\n```js\nconst page = await browser.newPage();\nawait page.goto('https://keycode.info');\nawait page.keyboard.press('A');\nawait page.screenshot({ path: 'A.png' });\nawait page.keyboard.press('ArrowLeft');\nawait page.screenshot({ path: 'ArrowLeft.png' });\nawait page.keyboard.press('Shift+O');\nawait page.screenshot({ path: 'O.png' });\nawait browser.close();\n```\n\nShortcut for [keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboarddownkey) and\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboardupkey)."
1031
+ "description": "`key` can specify the intended [keyboardEvent.key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key)\nvalue or a single character to generate the text for. A superset of the `key` values can be found\n[here](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values). Examples of the keys are:\n\n`F1` - `F12`, `Digit0`- `Digit9`, `KeyA`- `KeyZ`, `Backquote`, `Minus`, `Equal`, `Backslash`, `Backspace`, `Tab`,\n`Delete`, `Escape`, `ArrowDown`, `End`, `Enter`, `Home`, `Insert`, `PageDown`, `PageUp`, `ArrowRight`, `ArrowUp`, etc.\n\nFollowing modification shortcuts are also supported: `Shift`, `Control`, `Alt`, `Meta`, `ShiftLeft`.\n\nHolding down `Shift` will type the text that corresponds to the `key` in the upper case.\n\nIf `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective\ntexts.\n\nShortcuts such as `key: \"Control+o\"` or `key: \"Control+Shift+T\"` are supported as well. When specified with the\nmodifier, modifier is pressed and being held while the subsequent key is being pressed.\n\n```js\nconst page = await browser.newPage();\nawait page.goto('https://keycode.info');\nawait page.keyboard.press('A');\nawait page.screenshot({ path: 'A.png' });\nawait page.keyboard.press('ArrowLeft');\nawait page.screenshot({ path: 'ArrowLeft.png' });\nawait page.keyboard.press('Shift+O');\nawait page.screenshot({ path: 'O.png' });\nawait browser.close();\n```\n\nShortcut for [keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-down) and\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-up)."
966
1032
  },
967
1033
  "type": {
968
1034
  "kind": "function",
@@ -986,7 +1052,7 @@
986
1052
  "required": [
987
1053
  "text"
988
1054
  ],
989
- "description": "Sends a `keydown`, `keypress`/`input`, and `keyup` event for each character in the text.\n\nTo press a special key, like `Control` or `ArrowDown`, use\n[keyboard.press(key[, options])](https://playwright.dev/docs/api/class-keyboard#keyboardpresskey-options).\n\n```js\nawait page.keyboard.type('Hello'); // Types instantly\nawait page.keyboard.type('World', {delay: 100}); // Types slower, like a user\n```\n\n> NOTE: Modifier keys DO NOT effect `keyboard.type`. Holding down `Shift` will not type the text in upper case."
1055
+ "description": "Sends a `keydown`, `keypress`/`input`, and `keyup` event for each character in the text.\n\nTo press a special key, like `Control` or `ArrowDown`, use\n[keyboard.press(key[, options])](https://playwright.dev/docs/api/class-keyboard#keyboard-press).\n\n```js\nawait page.keyboard.type('Hello'); // Types instantly\nawait page.keyboard.type('World', {delay: 100}); // Types slower, like a user\n```\n\n> NOTE: Modifier keys DO NOT effect `keyboard.type`. Holding down `Shift` will not type the text in upper case.\n> NOTE: For characters that are not on a US keyboard, only an `input` event will be sent."
990
1056
  },
991
1057
  "up": {
992
1058
  "kind": "function",
@@ -1011,7 +1077,7 @@
1011
1077
  "up"
1012
1078
  ],
1013
1079
  "additionalProperties": false,
1014
- "description": "Keyboard provides an api for managing a virtual keyboard. The high level api is\n[keyboard.type(text[, options])](https://playwright.dev/docs/api/class-keyboard#keyboardtypetext-options), which takes\nraw characters and generates proper keydown, keypress/input, and keyup events on your page.\n\nFor finer control, you can use [keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboarddownkey),\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboardupkey), and\n[keyboard.insertText(text)](https://playwright.dev/docs/api/class-keyboard#keyboardinserttexttext) to manually fire\nevents as if they were generated from a real keyboard.\n\nAn example of holding down `Shift` in order to select and delete some text:\n\n```js\nawait page.keyboard.type('Hello World!');\nawait page.keyboard.press('ArrowLeft');\n\nawait page.keyboard.down('Shift');\nfor (let i = 0; i < ' World'.length; i++)\n await page.keyboard.press('ArrowLeft');\nawait page.keyboard.up('Shift');\n\nawait page.keyboard.press('Backspace');\n// Result text will end up saying 'Hello!'\n```\n\nAn example of pressing uppercase `A`\n\n```js\nawait page.keyboard.press('Shift+KeyA');\n// or\nawait page.keyboard.press('Shift+A');\n```\n\nAn example to trigger select-all with the keyboard\n\n```js\n// on Windows and Linux\nawait page.keyboard.press('Control+A');\n// on macOS\nawait page.keyboard.press('Meta+A');\n```"
1080
+ "description": "Keyboard provides an api for managing a virtual keyboard. The high level api is\n[keyboard.type(text[, options])](https://playwright.dev/docs/api/class-keyboard#keyboard-type), which takes raw\ncharacters and generates proper keydown, keypress/input, and keyup events on your page.\n\nFor finer control, you can use [keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-down),\n[keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-up), and\n[keyboard.insertText(text)](https://playwright.dev/docs/api/class-keyboard#keyboard-insert-text) to manually fire events\nas if they were generated from a real keyboard.\n\nAn example of holding down `Shift` in order to select and delete some text:\n\n```js\nawait page.keyboard.type('Hello World!');\nawait page.keyboard.press('ArrowLeft');\n\nawait page.keyboard.down('Shift');\nfor (let i = 0; i < ' World'.length; i++)\n await page.keyboard.press('ArrowLeft');\nawait page.keyboard.up('Shift');\n\nawait page.keyboard.press('Backspace');\n// Result text will end up saying 'Hello!'\n```\n\nAn example of pressing uppercase `A`\n\n```js\nawait page.keyboard.press('Shift+KeyA');\n// or\nawait page.keyboard.press('Shift+A');\n```\n\nAn example to trigger select-all with the keyboard\n\n```js\n// on Windows and Linux\nawait page.keyboard.press('Control+A');\n// on macOS\nawait page.keyboard.press('Meta+A');\n```"
1015
1081
  },
1016
1082
  "mouse": {
1017
1083
  "type": "object",
@@ -1054,7 +1120,7 @@
1054
1120
  "x",
1055
1121
  "y"
1056
1122
  ],
1057
- "description": "Shortcut for [mouse.move(x, y[, options])](https://playwright.dev/docs/api/class-mouse#mousemovex-y-options),\n[mouse.down([options])](https://playwright.dev/docs/api/class-mouse#mousedownoptions),\n[mouse.up([options])](https://playwright.dev/docs/api/class-mouse#mouseupoptions)."
1123
+ "description": "Shortcut for [mouse.move(x, y[, options])](https://playwright.dev/docs/api/class-mouse#mouse-move),\n[mouse.down([options])](https://playwright.dev/docs/api/class-mouse#mouse-down),\n[mouse.up([options])](https://playwright.dev/docs/api/class-mouse#mouse-up)."
1058
1124
  },
1059
1125
  "dblclick": {
1060
1126
  "kind": "function",
@@ -1090,7 +1156,7 @@
1090
1156
  "x",
1091
1157
  "y"
1092
1158
  ],
1093
- "description": "Shortcut for [mouse.move(x, y[, options])](https://playwright.dev/docs/api/class-mouse#mousemovex-y-options),\n[mouse.down([options])](https://playwright.dev/docs/api/class-mouse#mousedownoptions),\n[mouse.up([options])](https://playwright.dev/docs/api/class-mouse#mouseupoptions),\n[mouse.down([options])](https://playwright.dev/docs/api/class-mouse#mousedownoptions) and\n[mouse.up([options])](https://playwright.dev/docs/api/class-mouse#mouseupoptions)."
1159
+ "description": "Shortcut for [mouse.move(x, y[, options])](https://playwright.dev/docs/api/class-mouse#mouse-move),\n[mouse.down([options])](https://playwright.dev/docs/api/class-mouse#mouse-down),\n[mouse.up([options])](https://playwright.dev/docs/api/class-mouse#mouse-up),\n[mouse.down([options])](https://playwright.dev/docs/api/class-mouse#mouse-down) and\n[mouse.up([options])](https://playwright.dev/docs/api/class-mouse#mouse-up)."
1094
1160
  },
1095
1161
  "down": {
1096
1162
  "kind": "function",
@@ -1182,7 +1248,7 @@
1182
1248
  "up"
1183
1249
  ],
1184
1250
  "additionalProperties": false,
1185
- "description": "The Mouse class operates in main-frame CSS pixels relative to the top-left corner of the viewport.\n\nEvery `page` object has its own Mouse, accessible with\n[page.mouse](https://playwright.dev/docs/api/class-page#pagemouse).\n\n```js\n// Using ‘page.mouse’ to trace a 100x100 square.\nawait page.mouse.move(0, 0);\nawait page.mouse.down();\nawait page.mouse.move(0, 100);\nawait page.mouse.move(100, 100);\nawait page.mouse.move(100, 0);\nawait page.mouse.move(0, 0);\nawait page.mouse.up();\n```"
1251
+ "description": "The Mouse class operates in main-frame CSS pixels relative to the top-left corner of the viewport.\n\nEvery `page` object has its own Mouse, accessible with\n[page.mouse](https://playwright.dev/docs/api/class-page#page-mouse).\n\n```js\n// Using ‘page.mouse’ to trace a 100x100 square.\nawait page.mouse.move(0, 0);\nawait page.mouse.down();\nawait page.mouse.move(0, 100);\nawait page.mouse.move(100, 100);\nawait page.mouse.move(100, 0);\nawait page.mouse.move(0, 0);\nawait page.mouse.up();\n```"
1186
1252
  },
1187
1253
  "press": {
1188
1254
  "kind": "function",
@@ -1190,7 +1256,7 @@
1190
1256
  "parameters": {
1191
1257
  "selector": {
1192
1258
  "type": "string",
1193
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
1259
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
1194
1260
  },
1195
1261
  "key": {
1196
1262
  "type": "string",
@@ -1207,9 +1273,13 @@
1207
1273
  "type": "boolean",
1208
1274
  "description": "Actions that initiate navigations are waiting for these navigations to happen and for pages to start loading. You can\nopt out of waiting via setting this flag. You would only need this option in the exceptional cases such as navigating to\ninaccessible pages. Defaults to `false`."
1209
1275
  },
1276
+ "strict": {
1277
+ "type": "boolean",
1278
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
1279
+ },
1210
1280
  "timeout": {
1211
1281
  "type": "number",
1212
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
1282
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
1213
1283
  }
1214
1284
  },
1215
1285
  "additionalProperties": false
@@ -1219,7 +1289,7 @@
1219
1289
  "selector",
1220
1290
  "key"
1221
1291
  ],
1222
- "description": "Focuses the element, and then uses [keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboarddownkey)\nand [keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboardupkey).\n\n`key` can specify the intended [keyboardEvent.key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key)\nvalue or a single character to generate the text for. A superset of the `key` values can be found\n[here](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values). Examples of the keys are:\n\n`F1` - `F12`, `Digit0`- `Digit9`, `KeyA`- `KeyZ`, `Backquote`, `Minus`, `Equal`, `Backslash`, `Backspace`, `Tab`,\n`Delete`, `Escape`, `ArrowDown`, `End`, `Enter`, `Home`, `Insert`, `PageDown`, `PageUp`, `ArrowRight`, `ArrowUp`, etc.\n\nFollowing modification shortcuts are also supported: `Shift`, `Control`, `Alt`, `Meta`, `ShiftLeft`.\n\nHolding down `Shift` will type the text that corresponds to the `key` in the upper case.\n\nIf `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective\ntexts.\n\nShortcuts such as `key: \"Control+o\"` or `key: \"Control+Shift+T\"` are supported as well. When speficied with the\nmodifier, modifier is pressed and being held while the subsequent key is being pressed.\n\n```js\nconst page = await browser.newPage();\nawait page.goto('https://keycode.info');\nawait page.press('body', 'A');\nawait page.screenshot({ path: 'A.png' });\nawait page.press('body', 'ArrowLeft');\nawait page.screenshot({ path: 'ArrowLeft.png' });\nawait page.press('body', 'Shift+O');\nawait page.screenshot({ path: 'O.png' });\nawait browser.close();\n```"
1292
+ "description": "Focuses the element, and then uses [keyboard.down(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-down)\nand [keyboard.up(key)](https://playwright.dev/docs/api/class-keyboard#keyboard-up).\n\n`key` can specify the intended [keyboardEvent.key](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key)\nvalue or a single character to generate the text for. A superset of the `key` values can be found\n[here](https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values). Examples of the keys are:\n\n`F1` - `F12`, `Digit0`- `Digit9`, `KeyA`- `KeyZ`, `Backquote`, `Minus`, `Equal`, `Backslash`, `Backspace`, `Tab`,\n`Delete`, `Escape`, `ArrowDown`, `End`, `Enter`, `Home`, `Insert`, `PageDown`, `PageUp`, `ArrowRight`, `ArrowUp`, etc.\n\nFollowing modification shortcuts are also supported: `Shift`, `Control`, `Alt`, `Meta`, `ShiftLeft`.\n\nHolding down `Shift` will type the text that corresponds to the `key` in the upper case.\n\nIf `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective\ntexts.\n\nShortcuts such as `key: \"Control+o\"` or `key: \"Control+Shift+T\"` are supported as well. When specified with the\nmodifier, modifier is pressed and being held while the subsequent key is being pressed.\n\n```js\nconst page = await browser.newPage();\nawait page.goto('https://keycode.info');\nawait page.press('body', 'A');\nawait page.screenshot({ path: 'A.png' });\nawait page.press('body', 'ArrowLeft');\nawait page.screenshot({ path: 'ArrowLeft.png' });\nawait page.press('body', 'Shift+O');\nawait page.screenshot({ path: 'O.png' });\nawait browser.close();\n```"
1223
1293
  },
1224
1294
  "touchscreen": {
1225
1295
  "type": "object",
@@ -1246,7 +1316,7 @@
1246
1316
  "tap"
1247
1317
  ],
1248
1318
  "additionalProperties": false,
1249
- "description": "The Touchscreen class operates in main-frame CSS pixels relative to the top-left corner of the viewport. Methods on the\ntouchscreen can only be used in browser contexts that have been intialized with `hasTouch` set to true."
1319
+ "description": "The Touchscreen class operates in main-frame CSS pixels relative to the top-left corner of the viewport. Methods on the\ntouchscreen can only be used in browser contexts that have been initialized with `hasTouch` set to true."
1250
1320
  },
1251
1321
  "type": {
1252
1322
  "kind": "function",
@@ -1254,7 +1324,7 @@
1254
1324
  "parameters": {
1255
1325
  "selector": {
1256
1326
  "type": "string",
1257
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
1327
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
1258
1328
  },
1259
1329
  "text": {
1260
1330
  "type": "string",
@@ -1271,9 +1341,13 @@
1271
1341
  "type": "boolean",
1272
1342
  "description": "Actions that initiate navigations are waiting for these navigations to happen and for pages to start loading. You can\nopt out of waiting via setting this flag. You would only need this option in the exceptional cases such as navigating to\ninaccessible pages. Defaults to `false`."
1273
1343
  },
1344
+ "strict": {
1345
+ "type": "boolean",
1346
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
1347
+ },
1274
1348
  "timeout": {
1275
1349
  "type": "number",
1276
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
1350
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
1277
1351
  }
1278
1352
  },
1279
1353
  "additionalProperties": false
@@ -1283,7 +1357,7 @@
1283
1357
  "selector",
1284
1358
  "text"
1285
1359
  ],
1286
- "description": "Sends a `keydown`, `keypress`/`input`, and `keyup` event for each character in the text. `page.type` can be used to send\nfine-grained keyboard events. To fill values in form fields, use\n[page.fill(selector, value[, options])](https://playwright.dev/docs/api/class-page#pagefillselector-value-options).\n\nTo press a special key, like `Control` or `ArrowDown`, use\n[keyboard.press(key[, options])](https://playwright.dev/docs/api/class-keyboard#keyboardpresskey-options).\n\n```js\nawait page.type('#mytextarea', 'Hello'); // Types instantly\nawait page.type('#mytextarea', 'World', {delay: 100}); // Types slower, like a user\n```\n\nShortcut for main frame's\n[frame.type(selector, text[, options])](https://playwright.dev/docs/api/class-frame#frametypeselector-text-options)."
1360
+ "description": "Sends a `keydown`, `keypress`/`input`, and `keyup` event for each character in the text. `page.type` can be used to send\nfine-grained keyboard events. To fill values in form fields, use\n[page.fill(selector, value[, options])](https://playwright.dev/docs/api/class-page#page-fill).\n\nTo press a special key, like `Control` or `ArrowDown`, use\n[keyboard.press(key[, options])](https://playwright.dev/docs/api/class-keyboard#keyboard-press).\n\n```js\nawait page.type('#mytextarea', 'Hello'); // Types instantly\nawait page.type('#mytextarea', 'World', {delay: 100}); // Types slower, like a user\n```\n\nShortcut for main frame's\n[frame.type(selector, text[, options])](https://playwright.dev/docs/api/class-frame#frame-type)."
1287
1361
  },
1288
1362
  "uncheck": {
1289
1363
  "kind": "function",
@@ -1291,7 +1365,7 @@
1291
1365
  "parameters": {
1292
1366
  "selector": {
1293
1367
  "type": "string",
1294
- "description": "A selector to search for element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
1368
+ "description": "A selector to search for an element. If there are multiple elements satisfying the selector, the first will be used. See [working with selectors](https://playwright.dev/docs/selectors) for more details."
1295
1369
  },
1296
1370
  "options": {
1297
1371
  "type": "object",
@@ -1304,9 +1378,34 @@
1304
1378
  "type": "boolean",
1305
1379
  "description": "Actions that initiate navigations are waiting for these navigations to happen and for pages to start loading. You can\nopt out of waiting via setting this flag. You would only need this option in the exceptional cases such as navigating to\ninaccessible pages. Defaults to `false`."
1306
1380
  },
1381
+ "position": {
1382
+ "type": "object",
1383
+ "properties": {
1384
+ "x": {
1385
+ "type": "number"
1386
+ },
1387
+ "y": {
1388
+ "type": "number"
1389
+ }
1390
+ },
1391
+ "required": [
1392
+ "x",
1393
+ "y"
1394
+ ],
1395
+ "additionalProperties": false,
1396
+ "description": "A point to use relative to the top-left corner of element padding box. If not specified, uses some visible point of the\nelement."
1397
+ },
1398
+ "strict": {
1399
+ "type": "boolean",
1400
+ "description": "When true, the call requires selector to resolve to a single element. If given selector resolves to more then one\nelement, the call throws an exception."
1401
+ },
1307
1402
  "timeout": {
1308
1403
  "type": "number",
1309
- "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browsercontextsetdefaulttimeouttimeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#pagesetdefaulttimeouttimeout) methods."
1404
+ "description": "Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by\nusing the\n[browserContext.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-browsercontext#browser-context-set-default-timeout)\nor [page.setDefaultTimeout(timeout)](https://playwright.dev/docs/api/class-page#page-set-default-timeout) methods."
1405
+ },
1406
+ "trial": {
1407
+ "type": "boolean",
1408
+ "description": "When set, this method only performs the [actionability](https://playwright.dev/docs/actionability) checks and skips the action. Defaults to\n`false`. Useful to wait until the element is ready for the action without performing it."
1310
1409
  }
1311
1410
  },
1312
1411
  "additionalProperties": false
@@ -1315,7 +1414,7 @@
1315
1414
  "required": [
1316
1415
  "selector"
1317
1416
  ],
1318
- "description": "This method unchecks an element matching `selector` by performing the following steps:\n1. Find an element match matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Ensure that matched element is a checkbox or a radio input. If not, this method rejects. If the element is already\n unchecked, this method returns immediately.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#pagemouse) to click in the center of the element.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n1. Ensure that the element is now unchecked. If not, this method rejects.\n\nWhen all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError].\nPassing zero timeout disables this.\n\nShortcut for main frame's\n[frame.uncheck(selector[, options])](https://playwright.dev/docs/api/class-frame#frameuncheckselector-options)."
1417
+ "description": "This method unchecks an element matching `selector` by performing the following steps:\n1. Find an element matching `selector`. If there is none, wait until a matching element is attached to the DOM.\n1. Ensure that matched element is a checkbox or a radio input. If not, this method throws. If the element is already\n unchecked, this method returns immediately.\n1. Wait for [actionability](https://playwright.dev/docs/actionability) checks on the matched element, unless `force` option is set. If the\n element is detached during the checks, the whole action is retried.\n1. Scroll the element into view if needed.\n1. Use [page.mouse](https://playwright.dev/docs/api/class-page#page-mouse) to click in the center of the element.\n1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.\n1. Ensure that the element is now unchecked. If not, this method throws.\n\nWhen all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing\nzero timeout disables this.\n\nShortcut for main frame's\n[frame.uncheck(selector[, options])](https://playwright.dev/docs/api/class-frame#frame-uncheck)."
1319
1418
  },
1320
1419
  "waitForTimeout": {
1321
1420
  "kind": "function",
@@ -1329,7 +1428,7 @@
1329
1428
  "required": [
1330
1429
  "timeout"
1331
1430
  ],
1332
- "description": "Waits for the given `timeout` in milliseconds.\n\nNote that `page.waitForTimeout()` should only be used for debugging. Tests using the timer in production are going to be\nflaky. Use signals such as network events, selectors becoming visible and others instead.\n\n```js\n// wait for 1 second\nawait page.waitForTimeout(1000);\n```\n\nShortcut for main frame's\n[frame.waitForTimeout(timeout)](https://playwright.dev/docs/api/class-frame#framewaitfortimeouttimeout)."
1431
+ "description": "Waits for the given `timeout` in milliseconds.\n\nNote that `page.waitForTimeout()` should only be used for debugging. Tests using the timer in production are going to be\nflaky. Use signals such as network events, selectors becoming visible and others instead.\n\n```js\n// wait for 1 second\nawait page.waitForTimeout(1000);\n```\n\nShortcut for main frame's\n[frame.waitForTimeout(timeout)](https://playwright.dev/docs/api/class-frame#frame-wait-for-timeout)."
1333
1432
  },
1334
1433
  "takeScreenshot": {
1335
1434
  "kind": "function",