devtools-protocol 0.0.1591961 → 0.0.1593706
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.
|
@@ -11068,6 +11068,13 @@
|
|
|
11068
11068
|
"overlay",
|
|
11069
11069
|
"default"
|
|
11070
11070
|
]
|
|
11071
|
+
},
|
|
11072
|
+
{
|
|
11073
|
+
"name": "screenOrientationLockEmulation",
|
|
11074
|
+
"description": "If set to true, enables screen orientation lock emulation, which\nintercepts screen.orientation.lock() calls from the page and reports\norientation changes via screenOrientationLockChanged events. This is\nuseful for emulating mobile device orientation lock behavior in\nresponsive design mode.",
|
|
11075
|
+
"experimental": true,
|
|
11076
|
+
"optional": true,
|
|
11077
|
+
"type": "boolean"
|
|
11071
11078
|
}
|
|
11072
11079
|
]
|
|
11073
11080
|
},
|
|
@@ -11681,6 +11688,84 @@
|
|
|
11681
11688
|
}
|
|
11682
11689
|
]
|
|
11683
11690
|
},
|
|
11691
|
+
{
|
|
11692
|
+
"name": "updateScreen",
|
|
11693
|
+
"description": "Updates specified screen parameters. Only supported in headless mode.",
|
|
11694
|
+
"experimental": true,
|
|
11695
|
+
"parameters": [
|
|
11696
|
+
{
|
|
11697
|
+
"name": "screenId",
|
|
11698
|
+
"description": "Target screen identifier.",
|
|
11699
|
+
"$ref": "ScreenId"
|
|
11700
|
+
},
|
|
11701
|
+
{
|
|
11702
|
+
"name": "left",
|
|
11703
|
+
"description": "Offset of the left edge of the screen in pixels.",
|
|
11704
|
+
"optional": true,
|
|
11705
|
+
"type": "integer"
|
|
11706
|
+
},
|
|
11707
|
+
{
|
|
11708
|
+
"name": "top",
|
|
11709
|
+
"description": "Offset of the top edge of the screen in pixels.",
|
|
11710
|
+
"optional": true,
|
|
11711
|
+
"type": "integer"
|
|
11712
|
+
},
|
|
11713
|
+
{
|
|
11714
|
+
"name": "width",
|
|
11715
|
+
"description": "The width of the screen in pixels.",
|
|
11716
|
+
"optional": true,
|
|
11717
|
+
"type": "integer"
|
|
11718
|
+
},
|
|
11719
|
+
{
|
|
11720
|
+
"name": "height",
|
|
11721
|
+
"description": "The height of the screen in pixels.",
|
|
11722
|
+
"optional": true,
|
|
11723
|
+
"type": "integer"
|
|
11724
|
+
},
|
|
11725
|
+
{
|
|
11726
|
+
"name": "workAreaInsets",
|
|
11727
|
+
"description": "Specifies the screen's work area.",
|
|
11728
|
+
"optional": true,
|
|
11729
|
+
"$ref": "WorkAreaInsets"
|
|
11730
|
+
},
|
|
11731
|
+
{
|
|
11732
|
+
"name": "devicePixelRatio",
|
|
11733
|
+
"description": "Specifies the screen's device pixel ratio.",
|
|
11734
|
+
"optional": true,
|
|
11735
|
+
"type": "number"
|
|
11736
|
+
},
|
|
11737
|
+
{
|
|
11738
|
+
"name": "rotation",
|
|
11739
|
+
"description": "Specifies the screen's rotation angle. Available values are 0, 90, 180 and 270.",
|
|
11740
|
+
"optional": true,
|
|
11741
|
+
"type": "integer"
|
|
11742
|
+
},
|
|
11743
|
+
{
|
|
11744
|
+
"name": "colorDepth",
|
|
11745
|
+
"description": "Specifies the screen's color depth in bits.",
|
|
11746
|
+
"optional": true,
|
|
11747
|
+
"type": "integer"
|
|
11748
|
+
},
|
|
11749
|
+
{
|
|
11750
|
+
"name": "label",
|
|
11751
|
+
"description": "Specifies the descriptive label for the screen.",
|
|
11752
|
+
"optional": true,
|
|
11753
|
+
"type": "string"
|
|
11754
|
+
},
|
|
11755
|
+
{
|
|
11756
|
+
"name": "isInternal",
|
|
11757
|
+
"description": "Indicates whether the screen is internal to the device or external, attached to the device. Default is false.",
|
|
11758
|
+
"optional": true,
|
|
11759
|
+
"type": "boolean"
|
|
11760
|
+
}
|
|
11761
|
+
],
|
|
11762
|
+
"returns": [
|
|
11763
|
+
{
|
|
11764
|
+
"name": "screenInfo",
|
|
11765
|
+
"$ref": "ScreenInfo"
|
|
11766
|
+
}
|
|
11767
|
+
]
|
|
11768
|
+
},
|
|
11684
11769
|
{
|
|
11685
11770
|
"name": "removeScreen",
|
|
11686
11771
|
"description": "Remove screen from the device. Only supported in headless mode.",
|
|
@@ -11709,6 +11794,24 @@
|
|
|
11709
11794
|
"name": "virtualTimeBudgetExpired",
|
|
11710
11795
|
"description": "Notification sent after the virtual time budget for the current VirtualTimePolicy has run out.",
|
|
11711
11796
|
"experimental": true
|
|
11797
|
+
},
|
|
11798
|
+
{
|
|
11799
|
+
"name": "screenOrientationLockChanged",
|
|
11800
|
+
"description": "Fired when a page calls screen.orientation.lock() or screen.orientation.unlock()\nwhile device emulation is enabled. This allows the DevTools frontend to update the\nemulated device orientation accordingly.",
|
|
11801
|
+
"experimental": true,
|
|
11802
|
+
"parameters": [
|
|
11803
|
+
{
|
|
11804
|
+
"name": "locked",
|
|
11805
|
+
"description": "Whether the screen orientation is currently locked.",
|
|
11806
|
+
"type": "boolean"
|
|
11807
|
+
},
|
|
11808
|
+
{
|
|
11809
|
+
"name": "orientation",
|
|
11810
|
+
"description": "The orientation lock type requested by the page. Only set when locked is true.",
|
|
11811
|
+
"optional": true,
|
|
11812
|
+
"$ref": "ScreenOrientation"
|
|
11813
|
+
}
|
|
11814
|
+
]
|
|
11712
11815
|
}
|
|
11713
11816
|
]
|
|
11714
11817
|
},
|
package/package.json
CHANGED
|
@@ -306,6 +306,12 @@ domain Emulation
|
|
|
306
306
|
# classic (occupying space within the layout) or overlay, depending
|
|
307
307
|
# on the platform. Note: if `mobile` is `true`, the default scrollbar type is `overlay`.
|
|
308
308
|
default
|
|
309
|
+
# If set to true, enables screen orientation lock emulation, which
|
|
310
|
+
# intercepts screen.orientation.lock() calls from the page and reports
|
|
311
|
+
# orientation changes via screenOrientationLockChanged events. This is
|
|
312
|
+
# useful for emulating mobile device orientation lock behavior in
|
|
313
|
+
# responsive design mode.
|
|
314
|
+
experimental optional boolean screenOrientationLockEmulation
|
|
309
315
|
|
|
310
316
|
# Start reporting the given posture value to the Device Posture API.
|
|
311
317
|
# This override can also be set in setDeviceMetricsOverride().
|
|
@@ -530,6 +536,16 @@ domain Emulation
|
|
|
530
536
|
# Notification sent after the virtual time budget for the current VirtualTimePolicy has run out.
|
|
531
537
|
experimental event virtualTimeBudgetExpired
|
|
532
538
|
|
|
539
|
+
# Fired when a page calls screen.orientation.lock() or screen.orientation.unlock()
|
|
540
|
+
# while device emulation is enabled. This allows the DevTools frontend to update the
|
|
541
|
+
# emulated device orientation accordingly.
|
|
542
|
+
experimental event screenOrientationLockChanged
|
|
543
|
+
parameters
|
|
544
|
+
# Whether the screen orientation is currently locked.
|
|
545
|
+
boolean locked
|
|
546
|
+
# The orientation lock type requested by the page. Only set when locked is true.
|
|
547
|
+
optional ScreenOrientation orientation
|
|
548
|
+
|
|
533
549
|
# Enum of image types that can be disabled.
|
|
534
550
|
experimental type DisabledImageType extends string
|
|
535
551
|
enum
|
|
@@ -613,6 +629,34 @@ domain Emulation
|
|
|
613
629
|
returns
|
|
614
630
|
ScreenInfo screenInfo
|
|
615
631
|
|
|
632
|
+
# Updates specified screen parameters. Only supported in headless mode.
|
|
633
|
+
experimental command updateScreen
|
|
634
|
+
parameters
|
|
635
|
+
# Target screen identifier.
|
|
636
|
+
ScreenId screenId
|
|
637
|
+
# Offset of the left edge of the screen in pixels.
|
|
638
|
+
optional integer left
|
|
639
|
+
# Offset of the top edge of the screen in pixels.
|
|
640
|
+
optional integer top
|
|
641
|
+
# The width of the screen in pixels.
|
|
642
|
+
optional integer width
|
|
643
|
+
# The height of the screen in pixels.
|
|
644
|
+
optional integer height
|
|
645
|
+
# Specifies the screen's work area.
|
|
646
|
+
optional WorkAreaInsets workAreaInsets
|
|
647
|
+
# Specifies the screen's device pixel ratio.
|
|
648
|
+
optional number devicePixelRatio
|
|
649
|
+
# Specifies the screen's rotation angle. Available values are 0, 90, 180 and 270.
|
|
650
|
+
optional integer rotation
|
|
651
|
+
# Specifies the screen's color depth in bits.
|
|
652
|
+
optional integer colorDepth
|
|
653
|
+
# Specifies the descriptive label for the screen.
|
|
654
|
+
optional string label
|
|
655
|
+
# Indicates whether the screen is internal to the device or external, attached to the device. Default is false.
|
|
656
|
+
optional boolean isInternal
|
|
657
|
+
returns
|
|
658
|
+
ScreenInfo screenInfo
|
|
659
|
+
|
|
616
660
|
# Remove screen from the device. Only supported in headless mode.
|
|
617
661
|
experimental command removeScreen
|
|
618
662
|
parameters
|
|
@@ -306,6 +306,13 @@ export namespace ProtocolMapping {
|
|
|
306
306
|
* @experimental
|
|
307
307
|
*/
|
|
308
308
|
'Emulation.virtualTimeBudgetExpired': [];
|
|
309
|
+
/**
|
|
310
|
+
* Fired when a page calls screen.orientation.lock() or screen.orientation.unlock()
|
|
311
|
+
* while device emulation is enabled. This allows the DevTools frontend to update the
|
|
312
|
+
* emulated device orientation accordingly.
|
|
313
|
+
* @experimental
|
|
314
|
+
*/
|
|
315
|
+
'Emulation.screenOrientationLockChanged': [Protocol.Emulation.ScreenOrientationLockChangedEvent];
|
|
309
316
|
'FedCm.dialogShown': [Protocol.FedCm.DialogShownEvent];
|
|
310
317
|
/**
|
|
311
318
|
* Triggered when a dialog is closed, either by user action, JS abort,
|
|
@@ -3583,6 +3590,14 @@ export namespace ProtocolMapping {
|
|
|
3583
3590
|
paramsType: [Protocol.Emulation.AddScreenRequest];
|
|
3584
3591
|
returnType: Protocol.Emulation.AddScreenResponse;
|
|
3585
3592
|
};
|
|
3593
|
+
/**
|
|
3594
|
+
* Updates specified screen parameters. Only supported in headless mode.
|
|
3595
|
+
* @experimental
|
|
3596
|
+
*/
|
|
3597
|
+
'Emulation.updateScreen': {
|
|
3598
|
+
paramsType: [Protocol.Emulation.UpdateScreenRequest];
|
|
3599
|
+
returnType: Protocol.Emulation.UpdateScreenResponse;
|
|
3600
|
+
};
|
|
3586
3601
|
/**
|
|
3587
3602
|
* Remove screen from the device. Only supported in headless mode.
|
|
3588
3603
|
* @experimental
|
|
@@ -2384,6 +2384,12 @@ export namespace ProtocolProxyApi {
|
|
|
2384
2384
|
*/
|
|
2385
2385
|
addScreen(params: Protocol.Emulation.AddScreenRequest): Promise<Protocol.Emulation.AddScreenResponse>;
|
|
2386
2386
|
|
|
2387
|
+
/**
|
|
2388
|
+
* Updates specified screen parameters. Only supported in headless mode.
|
|
2389
|
+
* @experimental
|
|
2390
|
+
*/
|
|
2391
|
+
updateScreen(params: Protocol.Emulation.UpdateScreenRequest): Promise<Protocol.Emulation.UpdateScreenResponse>;
|
|
2392
|
+
|
|
2387
2393
|
/**
|
|
2388
2394
|
* Remove screen from the device. Only supported in headless mode.
|
|
2389
2395
|
* @experimental
|
|
@@ -2405,6 +2411,14 @@ export namespace ProtocolProxyApi {
|
|
|
2405
2411
|
*/
|
|
2406
2412
|
on(event: 'virtualTimeBudgetExpired', listener: () => void): void;
|
|
2407
2413
|
|
|
2414
|
+
/**
|
|
2415
|
+
* Fired when a page calls screen.orientation.lock() or screen.orientation.unlock()
|
|
2416
|
+
* while device emulation is enabled. This allows the DevTools frontend to update the
|
|
2417
|
+
* emulated device orientation accordingly.
|
|
2418
|
+
* @experimental
|
|
2419
|
+
*/
|
|
2420
|
+
on(event: 'screenOrientationLockChanged', listener: (params: Protocol.Emulation.ScreenOrientationLockChangedEvent) => void): void;
|
|
2421
|
+
|
|
2408
2422
|
}
|
|
2409
2423
|
|
|
2410
2424
|
export interface EventBreakpointsApi {
|
|
@@ -2522,6 +2522,12 @@ export namespace ProtocolTestsProxyApi {
|
|
|
2522
2522
|
*/
|
|
2523
2523
|
addScreen(params: Protocol.Emulation.AddScreenRequest): Promise<{id: number, result: Protocol.Emulation.AddScreenResponse, sessionId: string}>;
|
|
2524
2524
|
|
|
2525
|
+
/**
|
|
2526
|
+
* Updates specified screen parameters. Only supported in headless mode.
|
|
2527
|
+
* @experimental
|
|
2528
|
+
*/
|
|
2529
|
+
updateScreen(params: Protocol.Emulation.UpdateScreenRequest): Promise<{id: number, result: Protocol.Emulation.UpdateScreenResponse, sessionId: string}>;
|
|
2530
|
+
|
|
2525
2531
|
/**
|
|
2526
2532
|
* Remove screen from the device. Only supported in headless mode.
|
|
2527
2533
|
* @experimental
|
|
@@ -2545,6 +2551,16 @@ export namespace ProtocolTestsProxyApi {
|
|
|
2545
2551
|
offVirtualTimeBudgetExpired(listener: () => void): void;
|
|
2546
2552
|
onceVirtualTimeBudgetExpired(eventMatcher?: () => boolean): Promise<void>;
|
|
2547
2553
|
|
|
2554
|
+
/**
|
|
2555
|
+
* Fired when a page calls screen.orientation.lock() or screen.orientation.unlock()
|
|
2556
|
+
* while device emulation is enabled. This allows the DevTools frontend to update the
|
|
2557
|
+
* emulated device orientation accordingly.
|
|
2558
|
+
* @experimental
|
|
2559
|
+
*/
|
|
2560
|
+
onScreenOrientationLockChanged(listener: (event: { params: Protocol.Emulation.ScreenOrientationLockChangedEvent }) => void): void;
|
|
2561
|
+
offScreenOrientationLockChanged(listener: (event: { params: Protocol.Emulation.ScreenOrientationLockChangedEvent }) => void): void;
|
|
2562
|
+
onceScreenOrientationLockChanged(eventMatcher?: (event: { params: Protocol.Emulation.ScreenOrientationLockChangedEvent }) => boolean): Promise<{ params: Protocol.Emulation.ScreenOrientationLockChangedEvent }>;
|
|
2563
|
+
|
|
2548
2564
|
}
|
|
2549
2565
|
|
|
2550
2566
|
export interface EventBreakpointsApi {
|
package/types/protocol.d.ts
CHANGED
|
@@ -9522,6 +9522,15 @@ export namespace Protocol {
|
|
|
9522
9522
|
* @experimental
|
|
9523
9523
|
*/
|
|
9524
9524
|
scrollbarType?: ('overlay' | 'default');
|
|
9525
|
+
/**
|
|
9526
|
+
* If set to true, enables screen orientation lock emulation, which
|
|
9527
|
+
* intercepts screen.orientation.lock() calls from the page and reports
|
|
9528
|
+
* orientation changes via screenOrientationLockChanged events. This is
|
|
9529
|
+
* useful for emulating mobile device orientation lock behavior in
|
|
9530
|
+
* responsive design mode.
|
|
9531
|
+
* @experimental
|
|
9532
|
+
*/
|
|
9533
|
+
screenOrientationLockEmulation?: boolean;
|
|
9525
9534
|
}
|
|
9526
9535
|
|
|
9527
9536
|
export interface SetDevicePostureOverrideRequest {
|
|
@@ -9865,6 +9874,57 @@ export namespace Protocol {
|
|
|
9865
9874
|
screenInfo: ScreenInfo;
|
|
9866
9875
|
}
|
|
9867
9876
|
|
|
9877
|
+
export interface UpdateScreenRequest {
|
|
9878
|
+
/**
|
|
9879
|
+
* Target screen identifier.
|
|
9880
|
+
*/
|
|
9881
|
+
screenId: ScreenId;
|
|
9882
|
+
/**
|
|
9883
|
+
* Offset of the left edge of the screen in pixels.
|
|
9884
|
+
*/
|
|
9885
|
+
left?: integer;
|
|
9886
|
+
/**
|
|
9887
|
+
* Offset of the top edge of the screen in pixels.
|
|
9888
|
+
*/
|
|
9889
|
+
top?: integer;
|
|
9890
|
+
/**
|
|
9891
|
+
* The width of the screen in pixels.
|
|
9892
|
+
*/
|
|
9893
|
+
width?: integer;
|
|
9894
|
+
/**
|
|
9895
|
+
* The height of the screen in pixels.
|
|
9896
|
+
*/
|
|
9897
|
+
height?: integer;
|
|
9898
|
+
/**
|
|
9899
|
+
* Specifies the screen's work area.
|
|
9900
|
+
*/
|
|
9901
|
+
workAreaInsets?: WorkAreaInsets;
|
|
9902
|
+
/**
|
|
9903
|
+
* Specifies the screen's device pixel ratio.
|
|
9904
|
+
*/
|
|
9905
|
+
devicePixelRatio?: number;
|
|
9906
|
+
/**
|
|
9907
|
+
* Specifies the screen's rotation angle. Available values are 0, 90, 180 and 270.
|
|
9908
|
+
*/
|
|
9909
|
+
rotation?: integer;
|
|
9910
|
+
/**
|
|
9911
|
+
* Specifies the screen's color depth in bits.
|
|
9912
|
+
*/
|
|
9913
|
+
colorDepth?: integer;
|
|
9914
|
+
/**
|
|
9915
|
+
* Specifies the descriptive label for the screen.
|
|
9916
|
+
*/
|
|
9917
|
+
label?: string;
|
|
9918
|
+
/**
|
|
9919
|
+
* Indicates whether the screen is internal to the device or external, attached to the device. Default is false.
|
|
9920
|
+
*/
|
|
9921
|
+
isInternal?: boolean;
|
|
9922
|
+
}
|
|
9923
|
+
|
|
9924
|
+
export interface UpdateScreenResponse {
|
|
9925
|
+
screenInfo: ScreenInfo;
|
|
9926
|
+
}
|
|
9927
|
+
|
|
9868
9928
|
export interface RemoveScreenRequest {
|
|
9869
9929
|
screenId: ScreenId;
|
|
9870
9930
|
}
|
|
@@ -9872,6 +9932,23 @@ export namespace Protocol {
|
|
|
9872
9932
|
export interface SetPrimaryScreenRequest {
|
|
9873
9933
|
screenId: ScreenId;
|
|
9874
9934
|
}
|
|
9935
|
+
|
|
9936
|
+
/**
|
|
9937
|
+
* Fired when a page calls screen.orientation.lock() or screen.orientation.unlock()
|
|
9938
|
+
* while device emulation is enabled. This allows the DevTools frontend to update the
|
|
9939
|
+
* emulated device orientation accordingly.
|
|
9940
|
+
* @experimental
|
|
9941
|
+
*/
|
|
9942
|
+
export interface ScreenOrientationLockChangedEvent {
|
|
9943
|
+
/**
|
|
9944
|
+
* Whether the screen orientation is currently locked.
|
|
9945
|
+
*/
|
|
9946
|
+
locked: boolean;
|
|
9947
|
+
/**
|
|
9948
|
+
* The orientation lock type requested by the page. Only set when locked is true.
|
|
9949
|
+
*/
|
|
9950
|
+
orientation?: ScreenOrientation;
|
|
9951
|
+
}
|
|
9875
9952
|
}
|
|
9876
9953
|
|
|
9877
9954
|
/**
|