chrome-devtools-frontend 1.0.934332 → 1.0.934857
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.
- package/config/gni/all_devtools_files.gni +0 -8
- package/config/gni/devtools_grd_files.gni +3 -3
- package/front_end/Tests.js +2 -2
- package/front_end/core/host/UserMetrics.ts +0 -1
- package/front_end/core/i18n/locales/en-US.json +3 -0
- package/front_end/core/i18n/locales/en-XL.json +3 -0
- package/front_end/core/root/Runtime.ts +0 -1
- package/front_end/core/sdk/DOMModel.ts +3 -3
- package/front_end/core/sdk/sdk-meta.ts +3 -0
- package/front_end/entrypoints/inspector_main/inspector_main-meta.ts +1 -0
- package/front_end/entrypoints/main/MainImpl.ts +1 -11
- package/front_end/entrypoints/main/main-meta.ts +2 -1
- package/front_end/entrypoints/shell/shell.json +0 -3
- package/front_end/models/emulation/EmulatedDevices.ts +306 -84
- package/front_end/panels/changes/changes-meta.ts +0 -3
- package/front_end/panels/elements/elements-meta.ts +5 -0
- package/front_end/panels/lighthouse/LighthouseProtocolService.ts +1 -5
- package/front_end/panels/mobile_throttling/mobile_throttling-meta.ts +1 -0
- package/front_end/panels/network/network-meta.ts +2 -0
- package/front_end/panels/profiler/profiler-meta.ts +1 -0
- package/front_end/panels/sensors/sensors-meta.ts +1 -0
- package/front_end/panels/sources/CallStackSidebarPane.ts +21 -0
- package/front_end/panels/sources/module.json +0 -2
- package/front_end/panels/sources/sources-meta.ts +12 -0
- package/front_end/panels/timeline/timeline-meta.ts +1 -0
- package/front_end/ui/components/text_editor/config.ts +1 -1
- package/front_end/ui/components/text_editor/theme.ts +8 -0
- package/front_end/ui/legacy/GlassPane.ts +4 -0
- package/front_end/ui/legacy/InspectorView.ts +0 -4
- package/front_end/ui/legacy/ViewManager.ts +10 -2
- package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +2 -1
- package/front_end/ui/legacy/components/object_ui/ObjectPopoverHelper.ts +4 -3
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +5 -5
- package/front_end/ui/legacy/components/object_ui/module.json +0 -6
- package/front_end/ui/legacy/components/perf_ui/perf_ui-meta.ts +1 -0
- package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +3 -1
- package/front_end/ui/legacy/components/quick_open/quick_open-meta.ts +0 -3
- package/front_end/ui/legacy/components/source_frame/source_frame-meta.ts +1 -0
- package/front_end/ui/legacy/themeColors.css +4 -0
- package/package.json +1 -1
- package/front_end/panels/changes/module.json +0 -7
- package/front_end/panels/snippets/module.json +0 -6
- package/front_end/ui/legacy/components/quick_open/module.json +0 -8
|
@@ -502,12 +502,14 @@ export class EmulatedDevicesList extends Common.ObjectWrapper.ObjectWrapper<Even
|
|
|
502
502
|
constructor() {
|
|
503
503
|
super();
|
|
504
504
|
|
|
505
|
-
this.#standardSetting = Common.Settings.Settings.instance().createSetting(
|
|
505
|
+
this.#standardSetting = Common.Settings.Settings.instance().createSetting(
|
|
506
|
+
'standardEmulatedDeviceList', [], Common.Settings.SettingStorageType.Synced);
|
|
506
507
|
this.#standardInternal = new Set();
|
|
507
508
|
this.listFromJSONV1(this.#standardSetting.get(), this.#standardInternal);
|
|
508
509
|
this.updateStandardDevices();
|
|
509
510
|
|
|
510
|
-
this.#customSetting = Common.Settings.Settings.instance().createSetting(
|
|
511
|
+
this.#customSetting = Common.Settings.Settings.instance().createSetting(
|
|
512
|
+
'customEmulatedDeviceList', [], Common.Settings.SettingStorageType.Synced);
|
|
511
513
|
this.#customInternal = new Set();
|
|
512
514
|
if (!this.listFromJSONV1(this.#customSetting.get(), this.#customInternal)) {
|
|
513
515
|
this.saveCustomDevices();
|
|
@@ -643,6 +645,288 @@ export interface JSONMode {
|
|
|
643
645
|
}
|
|
644
646
|
|
|
645
647
|
const emulatedDevices = [
|
|
648
|
+
{
|
|
649
|
+
'order': 10,
|
|
650
|
+
'show-by-default': true,
|
|
651
|
+
'title': 'iPhone SE',
|
|
652
|
+
'screen': {
|
|
653
|
+
'horizontal': {
|
|
654
|
+
'width': 667,
|
|
655
|
+
'height': 375,
|
|
656
|
+
},
|
|
657
|
+
'device-pixel-ratio': 2,
|
|
658
|
+
'vertical': {
|
|
659
|
+
'width': 375,
|
|
660
|
+
'height': 667,
|
|
661
|
+
},
|
|
662
|
+
},
|
|
663
|
+
'capabilities': ['touch', 'mobile'],
|
|
664
|
+
'user-agent':
|
|
665
|
+
'Mozilla/5.0 (iPhone; CPU iPhone OS 10_3_1 like Mac OS X) AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.0 Mobile/14E304 Safari/602.1',
|
|
666
|
+
'type': 'phone',
|
|
667
|
+
},
|
|
668
|
+
{
|
|
669
|
+
'order': 12,
|
|
670
|
+
'show-by-default': true,
|
|
671
|
+
'title': 'iPhone XR',
|
|
672
|
+
'screen': {
|
|
673
|
+
'horizontal': {
|
|
674
|
+
'width': 896,
|
|
675
|
+
'height': 414,
|
|
676
|
+
},
|
|
677
|
+
'device-pixel-ratio': 2,
|
|
678
|
+
'vertical': {
|
|
679
|
+
'width': 414,
|
|
680
|
+
'height': 896,
|
|
681
|
+
},
|
|
682
|
+
},
|
|
683
|
+
'capabilities': ['touch', 'mobile'],
|
|
684
|
+
'user-agent':
|
|
685
|
+
'Mozilla/5.0 (iPhone; CPU iPhone OS 10_3_1 like Mac OS X) AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.0 Mobile/14E304 Safari/602.1',
|
|
686
|
+
'type': 'phone',
|
|
687
|
+
},
|
|
688
|
+
{
|
|
689
|
+
'order': 14,
|
|
690
|
+
'show-by-default': true,
|
|
691
|
+
'title': 'iPhone 12 Pro',
|
|
692
|
+
'screen': {
|
|
693
|
+
'horizontal': {
|
|
694
|
+
'width': 844,
|
|
695
|
+
'height': 390,
|
|
696
|
+
},
|
|
697
|
+
'device-pixel-ratio': 3,
|
|
698
|
+
'vertical': {
|
|
699
|
+
'width': 390,
|
|
700
|
+
'height': 844,
|
|
701
|
+
},
|
|
702
|
+
},
|
|
703
|
+
'capabilities': ['touch', 'mobile'],
|
|
704
|
+
'user-agent':
|
|
705
|
+
'Mozilla/5.0 (iPhone; CPU iPhone OS 10_3_1 like Mac OS X) AppleWebKit/603.1.30 (KHTML, like Gecko) Version/10.0 Mobile/14E304 Safari/602.1',
|
|
706
|
+
'type': 'phone',
|
|
707
|
+
},
|
|
708
|
+
{
|
|
709
|
+
'order': 16,
|
|
710
|
+
'show-by-default': false,
|
|
711
|
+
'title': 'Pixel 3 XL',
|
|
712
|
+
'screen': {
|
|
713
|
+
'horizontal': {
|
|
714
|
+
'width': 786,
|
|
715
|
+
'height': 393,
|
|
716
|
+
},
|
|
717
|
+
'device-pixel-ratio': 2.75,
|
|
718
|
+
'vertical': {
|
|
719
|
+
'width': 393,
|
|
720
|
+
'height': 786,
|
|
721
|
+
},
|
|
722
|
+
},
|
|
723
|
+
'capabilities': ['touch', 'mobile'],
|
|
724
|
+
'user-agent':
|
|
725
|
+
'Mozilla/5.0 (Linux; Android 11; Pixel 3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.181 Mobile Safari/537.36',
|
|
726
|
+
'type': 'phone',
|
|
727
|
+
},
|
|
728
|
+
{
|
|
729
|
+
'order': 18,
|
|
730
|
+
'show-by-default': true,
|
|
731
|
+
'title': 'Pixel 5',
|
|
732
|
+
'screen': {
|
|
733
|
+
'horizontal': {
|
|
734
|
+
'width': 851,
|
|
735
|
+
'height': 393,
|
|
736
|
+
},
|
|
737
|
+
'device-pixel-ratio': 2.75,
|
|
738
|
+
'vertical': {
|
|
739
|
+
'width': 393,
|
|
740
|
+
'height': 851,
|
|
741
|
+
},
|
|
742
|
+
},
|
|
743
|
+
'capabilities': ['touch', 'mobile'],
|
|
744
|
+
'user-agent':
|
|
745
|
+
'Mozilla/5.0 (Linux; Android 11; Pixel 5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.91 Mobile Safari/537.36',
|
|
746
|
+
'type': 'phone',
|
|
747
|
+
},
|
|
748
|
+
{
|
|
749
|
+
'order': 20,
|
|
750
|
+
'show-by-default': true,
|
|
751
|
+
'title': 'Samsung Galaxy S8+',
|
|
752
|
+
'screen': {
|
|
753
|
+
'horizontal': {
|
|
754
|
+
'width': 740,
|
|
755
|
+
'height': 360,
|
|
756
|
+
},
|
|
757
|
+
'device-pixel-ratio': 4,
|
|
758
|
+
'vertical': {
|
|
759
|
+
'width': 360,
|
|
760
|
+
'height': 740,
|
|
761
|
+
},
|
|
762
|
+
},
|
|
763
|
+
'capabilities': ['touch', 'mobile'],
|
|
764
|
+
'user-agent':
|
|
765
|
+
'Mozilla/5.0 (Linux; Android 8.0.0; SM-G955U Build/R16NW) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Mobile Safari/537.36',
|
|
766
|
+
'type': 'phone',
|
|
767
|
+
},
|
|
768
|
+
{
|
|
769
|
+
'order': 24,
|
|
770
|
+
'show-by-default': true,
|
|
771
|
+
'title': 'Samsung Galaxy S20 Ultra',
|
|
772
|
+
'screen': {
|
|
773
|
+
'horizontal': {
|
|
774
|
+
'width': 915,
|
|
775
|
+
'height': 412,
|
|
776
|
+
},
|
|
777
|
+
'device-pixel-ratio': 3.5,
|
|
778
|
+
'vertical': {
|
|
779
|
+
'width': 412,
|
|
780
|
+
'height': 915,
|
|
781
|
+
},
|
|
782
|
+
},
|
|
783
|
+
'capabilities': ['touch', 'mobile'],
|
|
784
|
+
'user-agent':
|
|
785
|
+
'Mozilla/5.0 (Linux; Android 10; SM-G981B) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.162 Mobile Safari/537.36',
|
|
786
|
+
'type': 'phone',
|
|
787
|
+
},
|
|
788
|
+
{
|
|
789
|
+
'order': 26,
|
|
790
|
+
'show-by-default': true,
|
|
791
|
+
'title': 'iPad Air',
|
|
792
|
+
'screen': {
|
|
793
|
+
'horizontal': {
|
|
794
|
+
'width': 1180,
|
|
795
|
+
'height': 820,
|
|
796
|
+
},
|
|
797
|
+
'device-pixel-ratio': 2,
|
|
798
|
+
'vertical': {
|
|
799
|
+
'width': 820,
|
|
800
|
+
'height': 1180,
|
|
801
|
+
},
|
|
802
|
+
},
|
|
803
|
+
'capabilities': ['touch', 'mobile'],
|
|
804
|
+
'user-agent':
|
|
805
|
+
'Mozilla/5.0 (iPad; CPU OS 13_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/87.0.4280.77 Mobile/15E148 Safari/604.1',
|
|
806
|
+
'type': 'tablet',
|
|
807
|
+
},
|
|
808
|
+
{
|
|
809
|
+
'order': 28,
|
|
810
|
+
'show-by-default': true,
|
|
811
|
+
'title': 'iPad Mini',
|
|
812
|
+
'screen': {
|
|
813
|
+
'horizontal': {
|
|
814
|
+
'width': 1024,
|
|
815
|
+
'height': 768,
|
|
816
|
+
},
|
|
817
|
+
'device-pixel-ratio': 2,
|
|
818
|
+
'vertical': {
|
|
819
|
+
'width': 768,
|
|
820
|
+
'height': 1024,
|
|
821
|
+
},
|
|
822
|
+
},
|
|
823
|
+
'capabilities': ['touch', 'mobile'],
|
|
824
|
+
'user-agent':
|
|
825
|
+
'Mozilla/5.0 (iPad; CPU OS 13_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/87.0.4280.77 Mobile/15E148 Safari/604.1',
|
|
826
|
+
'type': 'tablet',
|
|
827
|
+
},
|
|
828
|
+
{
|
|
829
|
+
'order': 30,
|
|
830
|
+
'show-by-default': true,
|
|
831
|
+
'title': 'Surface Pro 7',
|
|
832
|
+
'screen': {
|
|
833
|
+
'horizontal': {
|
|
834
|
+
'width': 1368,
|
|
835
|
+
'height': 912,
|
|
836
|
+
},
|
|
837
|
+
'device-pixel-ratio': 2,
|
|
838
|
+
'vertical': {
|
|
839
|
+
'width': 912,
|
|
840
|
+
'height': 1368,
|
|
841
|
+
},
|
|
842
|
+
},
|
|
843
|
+
'capabilities': ['touch', 'mobile'],
|
|
844
|
+
'user-agent':
|
|
845
|
+
'Mozilla/5.0 (iPad; CPU OS 13_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/87.0.4280.77 Mobile/15E148 Safari/604.1',
|
|
846
|
+
'type': 'tablet',
|
|
847
|
+
},
|
|
848
|
+
{
|
|
849
|
+
'order': 32,
|
|
850
|
+
'show-by-default': true,
|
|
851
|
+
'dual-screen': true,
|
|
852
|
+
'title': 'Surface Duo',
|
|
853
|
+
'screen': {
|
|
854
|
+
'horizontal': {'width': 720, 'height': 540},
|
|
855
|
+
'device-pixel-ratio': 2.5,
|
|
856
|
+
'vertical': {'width': 540, 'height': 720},
|
|
857
|
+
'vertical-spanned': {
|
|
858
|
+
'width': 1114,
|
|
859
|
+
'height': 720,
|
|
860
|
+
'hinge': {'width': 34, 'height': 720, 'x': 540, 'y': 0, 'contentColor': {'r': 38, 'g': 38, 'b': 38, 'a': 1}},
|
|
861
|
+
},
|
|
862
|
+
'horizontal-spanned': {
|
|
863
|
+
'width': 720,
|
|
864
|
+
'height': 1114,
|
|
865
|
+
'hinge': {'width': 720, 'height': 34, 'x': 0, 'y': 540, 'contentColor': {'r': 38, 'g': 38, 'b': 38, 'a': 1}},
|
|
866
|
+
},
|
|
867
|
+
},
|
|
868
|
+
'capabilities': ['touch', 'mobile'],
|
|
869
|
+
'user-agent':
|
|
870
|
+
'Mozilla/5.0 (Linux; Android 8.0; Pixel 2 Build/OPD3.170816.012) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/%s Mobile Safari/537.36',
|
|
871
|
+
'type': 'phone',
|
|
872
|
+
'modes': [
|
|
873
|
+
{'title': 'default', 'orientation': 'vertical', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
874
|
+
{'title': 'default', 'orientation': 'horizontal', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
875
|
+
{'title': 'spanned', 'orientation': 'vertical-spanned', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
876
|
+
{
|
|
877
|
+
'title': 'spanned',
|
|
878
|
+
'orientation': 'horizontal-spanned',
|
|
879
|
+
'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0},
|
|
880
|
+
},
|
|
881
|
+
],
|
|
882
|
+
},
|
|
883
|
+
{
|
|
884
|
+
'order': 34,
|
|
885
|
+
'show-by-default': true,
|
|
886
|
+
'dual-screen': true,
|
|
887
|
+
'title': 'Galaxy Fold',
|
|
888
|
+
'screen': {
|
|
889
|
+
'horizontal': {'width': 653, 'height': 280},
|
|
890
|
+
'device-pixel-ratio': 3,
|
|
891
|
+
'vertical': {'width': 280, 'height': 653},
|
|
892
|
+
'vertical-spanned': {'width': 717, 'height': 512},
|
|
893
|
+
'horizontal-spanned': {'width': 512, 'height': 717},
|
|
894
|
+
},
|
|
895
|
+
'capabilities': ['touch', 'mobile'],
|
|
896
|
+
'user-agent':
|
|
897
|
+
'Mozilla/5.0 (Linux; Android 8.0; Pixel 2 Build/OPD3.170816.012) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/%s Mobile Safari/537.36',
|
|
898
|
+
'type': 'phone',
|
|
899
|
+
'modes': [
|
|
900
|
+
{'title': 'default', 'orientation': 'vertical', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
901
|
+
{'title': 'default', 'orientation': 'horizontal', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
902
|
+
{'title': 'spanned', 'orientation': 'vertical-spanned', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
903
|
+
{
|
|
904
|
+
'title': 'spanned',
|
|
905
|
+
'orientation': 'horizontal-spanned',
|
|
906
|
+
'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0},
|
|
907
|
+
},
|
|
908
|
+
],
|
|
909
|
+
},
|
|
910
|
+
{
|
|
911
|
+
'order': 36,
|
|
912
|
+
'show-by-default': true,
|
|
913
|
+
'title': 'Samsung Galaxy A51/71',
|
|
914
|
+
'screen': {
|
|
915
|
+
'horizontal': {
|
|
916
|
+
'width': 914,
|
|
917
|
+
'height': 412,
|
|
918
|
+
},
|
|
919
|
+
'device-pixel-ratio': 2.625,
|
|
920
|
+
'vertical': {
|
|
921
|
+
'width': 412,
|
|
922
|
+
'height': 914,
|
|
923
|
+
},
|
|
924
|
+
},
|
|
925
|
+
'capabilities': ['touch', 'mobile'],
|
|
926
|
+
'user-agent':
|
|
927
|
+
'Mozilla/5.0 (Linux; Android 8.0.0; SM-G955U Build/R16NW) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Mobile Safari/537.36',
|
|
928
|
+
'type': 'phone',
|
|
929
|
+
},
|
|
646
930
|
{
|
|
647
931
|
'order': 52,
|
|
648
932
|
'show-by-default': true,
|
|
@@ -668,7 +952,6 @@ const emulatedDevices = [
|
|
|
668
952
|
'type': 'tablet',
|
|
669
953
|
'modes': [{'title': 'default', 'orientation': 'horizontal'}],
|
|
670
954
|
},
|
|
671
|
-
|
|
672
955
|
{
|
|
673
956
|
'order': 50,
|
|
674
957
|
'show-by-default': true,
|
|
@@ -694,6 +977,7 @@ const emulatedDevices = [
|
|
|
694
977
|
'type': 'tablet',
|
|
695
978
|
'modes': [{'title': 'default', 'orientation': 'horizontal'}],
|
|
696
979
|
},
|
|
980
|
+
|
|
697
981
|
{
|
|
698
982
|
'show-by-default': false,
|
|
699
983
|
'title': 'iPhone 4',
|
|
@@ -708,8 +992,8 @@ const emulatedDevices = [
|
|
|
708
992
|
'type': 'phone',
|
|
709
993
|
},
|
|
710
994
|
{
|
|
711
|
-
'order':
|
|
712
|
-
'show-by-default':
|
|
995
|
+
'order': 130,
|
|
996
|
+
'show-by-default': false,
|
|
713
997
|
'title': 'iPhone 5/SE',
|
|
714
998
|
'screen': {
|
|
715
999
|
'horizontal': {
|
|
@@ -736,8 +1020,8 @@ const emulatedDevices = [
|
|
|
736
1020
|
'type': 'phone',
|
|
737
1021
|
},
|
|
738
1022
|
{
|
|
739
|
-
'order':
|
|
740
|
-
'show-by-default':
|
|
1023
|
+
'order': 131,
|
|
1024
|
+
'show-by-default': false,
|
|
741
1025
|
'title': 'iPhone 6/7/8',
|
|
742
1026
|
'screen': {
|
|
743
1027
|
'horizontal': {
|
|
@@ -764,8 +1048,8 @@ const emulatedDevices = [
|
|
|
764
1048
|
'type': 'phone',
|
|
765
1049
|
},
|
|
766
1050
|
{
|
|
767
|
-
'order':
|
|
768
|
-
'show-by-default':
|
|
1051
|
+
'order': 132,
|
|
1052
|
+
'show-by-default': false,
|
|
769
1053
|
'title': 'iPhone 6/7/8 Plus',
|
|
770
1054
|
'screen': {
|
|
771
1055
|
'horizontal': {
|
|
@@ -792,8 +1076,8 @@ const emulatedDevices = [
|
|
|
792
1076
|
'type': 'phone',
|
|
793
1077
|
},
|
|
794
1078
|
{
|
|
795
|
-
'order':
|
|
796
|
-
'show-by-default':
|
|
1079
|
+
'order': 133,
|
|
1080
|
+
'show-by-default': false,
|
|
797
1081
|
'title': 'iPhone X',
|
|
798
1082
|
'screen': {
|
|
799
1083
|
'horizontal': {'width': 812, 'height': 375},
|
|
@@ -1010,8 +1294,8 @@ const emulatedDevices = [
|
|
|
1010
1294
|
'type': 'phone',
|
|
1011
1295
|
},
|
|
1012
1296
|
{
|
|
1013
|
-
'order':
|
|
1014
|
-
'show-by-default':
|
|
1297
|
+
'order': 120,
|
|
1298
|
+
'show-by-default': false,
|
|
1015
1299
|
'title': 'Pixel 2',
|
|
1016
1300
|
'screen': {
|
|
1017
1301
|
'horizontal': {'width': 731, 'height': 411},
|
|
@@ -1026,8 +1310,8 @@ const emulatedDevices = [
|
|
|
1026
1310
|
'type': 'phone',
|
|
1027
1311
|
},
|
|
1028
1312
|
{
|
|
1029
|
-
'order':
|
|
1030
|
-
'show-by-default':
|
|
1313
|
+
'order': 121,
|
|
1314
|
+
'show-by-default': false,
|
|
1031
1315
|
'title': 'Pixel 2 XL',
|
|
1032
1316
|
'screen': {
|
|
1033
1317
|
'horizontal': {'width': 823, 'height': 411},
|
|
@@ -1154,8 +1438,8 @@ const emulatedDevices = [
|
|
|
1154
1438
|
'type': 'phone',
|
|
1155
1439
|
},
|
|
1156
1440
|
{
|
|
1157
|
-
'order':
|
|
1158
|
-
'show-by-default':
|
|
1441
|
+
'order': 110,
|
|
1442
|
+
'show-by-default': false,
|
|
1159
1443
|
'title': 'Galaxy S5',
|
|
1160
1444
|
'screen': {
|
|
1161
1445
|
'horizontal': {'width': 640, 'height': 360},
|
|
@@ -1255,8 +1539,8 @@ const emulatedDevices = [
|
|
|
1255
1539
|
'type': 'tablet',
|
|
1256
1540
|
},
|
|
1257
1541
|
{
|
|
1258
|
-
'order':
|
|
1259
|
-
'show-by-default':
|
|
1542
|
+
'order': 140,
|
|
1543
|
+
'show-by-default': false,
|
|
1260
1544
|
'title': 'iPad',
|
|
1261
1545
|
'screen': {
|
|
1262
1546
|
'horizontal': {
|
|
@@ -1283,8 +1567,8 @@ const emulatedDevices = [
|
|
|
1283
1567
|
'type': 'tablet',
|
|
1284
1568
|
},
|
|
1285
1569
|
{
|
|
1286
|
-
'order':
|
|
1287
|
-
'show-by-default':
|
|
1570
|
+
'order': 141,
|
|
1571
|
+
'show-by-default': false,
|
|
1288
1572
|
'title': 'iPad Pro',
|
|
1289
1573
|
'screen': {
|
|
1290
1574
|
'horizontal': {'width': 1366, 'height': 1024},
|
|
@@ -1409,7 +1693,7 @@ const emulatedDevices = [
|
|
|
1409
1693
|
'modes': [{'title': 'default', 'orientation': 'horizontal'}],
|
|
1410
1694
|
},
|
|
1411
1695
|
{
|
|
1412
|
-
'show-by-default':
|
|
1696
|
+
'show-by-default': false,
|
|
1413
1697
|
'title': 'Moto G4',
|
|
1414
1698
|
'screen': {
|
|
1415
1699
|
'horizontal': {
|
|
@@ -1437,66 +1721,4 @@ const emulatedDevices = [
|
|
|
1437
1721
|
{'platform': 'Android', 'platformVersion': '6.0.1', 'architecture': '', 'model': 'Moto G (4)', 'mobile': true},
|
|
1438
1722
|
'type': 'phone',
|
|
1439
1723
|
},
|
|
1440
|
-
{
|
|
1441
|
-
'order': 45,
|
|
1442
|
-
'show-by-default': true,
|
|
1443
|
-
'dual-screen': true,
|
|
1444
|
-
'title': 'Surface Duo',
|
|
1445
|
-
'screen': {
|
|
1446
|
-
'horizontal': {'width': 720, 'height': 540},
|
|
1447
|
-
'device-pixel-ratio': 2.5,
|
|
1448
|
-
'vertical': {'width': 540, 'height': 720},
|
|
1449
|
-
'vertical-spanned': {
|
|
1450
|
-
'width': 1114,
|
|
1451
|
-
'height': 720,
|
|
1452
|
-
'hinge': {'width': 34, 'height': 720, 'x': 540, 'y': 0, 'contentColor': {'r': 38, 'g': 38, 'b': 38, 'a': 1}},
|
|
1453
|
-
},
|
|
1454
|
-
'horizontal-spanned': {
|
|
1455
|
-
'width': 720,
|
|
1456
|
-
'height': 1114,
|
|
1457
|
-
'hinge': {'width': 720, 'height': 34, 'x': 0, 'y': 540, 'contentColor': {'r': 38, 'g': 38, 'b': 38, 'a': 1}},
|
|
1458
|
-
},
|
|
1459
|
-
},
|
|
1460
|
-
'capabilities': ['touch', 'mobile'],
|
|
1461
|
-
'user-agent':
|
|
1462
|
-
'Mozilla/5.0 (Linux; Android 8.0; Pixel 2 Build/OPD3.170816.012) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/%s Mobile Safari/537.36',
|
|
1463
|
-
'type': 'phone',
|
|
1464
|
-
'modes': [
|
|
1465
|
-
{'title': 'default', 'orientation': 'vertical', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
1466
|
-
{'title': 'default', 'orientation': 'horizontal', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
1467
|
-
{'title': 'spanned', 'orientation': 'vertical-spanned', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
1468
|
-
{
|
|
1469
|
-
'title': 'spanned',
|
|
1470
|
-
'orientation': 'horizontal-spanned',
|
|
1471
|
-
'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0},
|
|
1472
|
-
},
|
|
1473
|
-
],
|
|
1474
|
-
},
|
|
1475
|
-
{
|
|
1476
|
-
'order': 46,
|
|
1477
|
-
'show-by-default': true,
|
|
1478
|
-
'dual-screen': true,
|
|
1479
|
-
'title': 'Galaxy Fold',
|
|
1480
|
-
'screen': {
|
|
1481
|
-
'horizontal': {'width': 653, 'height': 280},
|
|
1482
|
-
'device-pixel-ratio': 3,
|
|
1483
|
-
'vertical': {'width': 280, 'height': 653},
|
|
1484
|
-
'vertical-spanned': {'width': 717, 'height': 512},
|
|
1485
|
-
'horizontal-spanned': {'width': 512, 'height': 717},
|
|
1486
|
-
},
|
|
1487
|
-
'capabilities': ['touch', 'mobile'],
|
|
1488
|
-
'user-agent':
|
|
1489
|
-
'Mozilla/5.0 (Linux; Android 8.0; Pixel 2 Build/OPD3.170816.012) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/%s Mobile Safari/537.36',
|
|
1490
|
-
'type': 'phone',
|
|
1491
|
-
'modes': [
|
|
1492
|
-
{'title': 'default', 'orientation': 'vertical', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
1493
|
-
{'title': 'default', 'orientation': 'horizontal', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
1494
|
-
{'title': 'spanned', 'orientation': 'vertical-spanned', 'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0}},
|
|
1495
|
-
{
|
|
1496
|
-
'title': 'spanned',
|
|
1497
|
-
'orientation': 'horizontal-spanned',
|
|
1498
|
-
'insets': {'left': 0, 'top': 0, 'right': 0, 'bottom': 0},
|
|
1499
|
-
},
|
|
1500
|
-
],
|
|
1501
|
-
},
|
|
1502
1724
|
];
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
import * as Common from '../../core/common/common.js';
|
|
6
6
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
7
|
-
import * as Root from '../../core/root/root.js';
|
|
8
7
|
import * as WorkspaceDiff from '../../models/workspace_diff/workspace_diff.js';
|
|
9
8
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
10
9
|
|
|
@@ -28,8 +27,6 @@ const i18nLazyString = i18n.i18n.getLazilyComputedLocalizedString.bind(undefined
|
|
|
28
27
|
|
|
29
28
|
async function loadChangesModule(): Promise<typeof Changes> {
|
|
30
29
|
if (!loadedChangesModule) {
|
|
31
|
-
// Side-effect import resources in module.json
|
|
32
|
-
await Root.Runtime.Runtime.instance().loadModulePromise('panels/changes');
|
|
33
30
|
loadedChangesModule = await import('./changes.js');
|
|
34
31
|
}
|
|
35
32
|
return loadedChangesModule;
|
|
@@ -379,6 +379,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
379
379
|
|
|
380
380
|
Common.Settings.registerSettingExtension({
|
|
381
381
|
category: Common.Settings.SettingCategory.ELEMENTS,
|
|
382
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
382
383
|
order: 1,
|
|
383
384
|
title: i18nLazyString(UIStrings.showUserAgentShadowDOM),
|
|
384
385
|
settingName: 'showUAShadowDOM',
|
|
@@ -388,6 +389,7 @@ Common.Settings.registerSettingExtension({
|
|
|
388
389
|
|
|
389
390
|
Common.Settings.registerSettingExtension({
|
|
390
391
|
category: Common.Settings.SettingCategory.ELEMENTS,
|
|
392
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
391
393
|
order: 2,
|
|
392
394
|
title: i18nLazyString(UIStrings.wordWrap),
|
|
393
395
|
settingName: 'domWordWrap',
|
|
@@ -407,6 +409,7 @@ Common.Settings.registerSettingExtension({
|
|
|
407
409
|
|
|
408
410
|
Common.Settings.registerSettingExtension({
|
|
409
411
|
category: Common.Settings.SettingCategory.ELEMENTS,
|
|
412
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
410
413
|
order: 3,
|
|
411
414
|
title: i18nLazyString(UIStrings.showHtmlComments),
|
|
412
415
|
settingName: 'showHTMLComments',
|
|
@@ -426,6 +429,7 @@ Common.Settings.registerSettingExtension({
|
|
|
426
429
|
|
|
427
430
|
Common.Settings.registerSettingExtension({
|
|
428
431
|
category: Common.Settings.SettingCategory.ELEMENTS,
|
|
432
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
429
433
|
order: 4,
|
|
430
434
|
title: i18nLazyString(UIStrings.revealDomNodeOnHover),
|
|
431
435
|
settingName: 'highlightNodeOnHoverInOverlay',
|
|
@@ -435,6 +439,7 @@ Common.Settings.registerSettingExtension({
|
|
|
435
439
|
|
|
436
440
|
Common.Settings.registerSettingExtension({
|
|
437
441
|
category: Common.Settings.SettingCategory.ELEMENTS,
|
|
442
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
438
443
|
order: 5,
|
|
439
444
|
title: i18nLazyString(UIStrings.showDetailedInspectTooltip),
|
|
440
445
|
settingName: 'showDetailedInspectTooltip',
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
6
6
|
import type * as ProtocolClient from '../../core/protocol_client/protocol_client.js';
|
|
7
7
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
8
|
-
import * as Root from '../../core/root/root.js';
|
|
9
8
|
|
|
10
9
|
import type * as ReportRenderer from './LighthouseReporterTypes.js';
|
|
11
10
|
|
|
@@ -35,10 +34,7 @@ export class ProtocolService {
|
|
|
35
34
|
}
|
|
36
35
|
|
|
37
36
|
getLocales(): readonly string[] {
|
|
38
|
-
|
|
39
|
-
return [i18n.DevToolsLocale.DevToolsLocale.instance().locale];
|
|
40
|
-
}
|
|
41
|
-
return navigator.languages;
|
|
37
|
+
return [i18n.DevToolsLocale.DevToolsLocale.instance().locale];
|
|
42
38
|
}
|
|
43
39
|
|
|
44
40
|
startLighthouse(auditURL: string, categoryIDs: string[], flags: Object): Promise<ReportRenderer.RunnerResult> {
|
|
@@ -132,6 +132,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
132
132
|
});
|
|
133
133
|
|
|
134
134
|
Common.Settings.registerSettingExtension({
|
|
135
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
135
136
|
settingName: 'customNetworkConditions',
|
|
136
137
|
settingType: Common.Settings.SettingType.ARRAY,
|
|
137
138
|
defaultValue: [],
|
|
@@ -275,6 +275,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
275
275
|
|
|
276
276
|
Common.Settings.registerSettingExtension({
|
|
277
277
|
category: Common.Settings.SettingCategory.NETWORK,
|
|
278
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
278
279
|
title: i18nLazyString(UIStrings.colorcodeResourceTypes),
|
|
279
280
|
settingName: 'networkColorCodeResourceTypes',
|
|
280
281
|
settingType: Common.Settings.SettingType.BOOLEAN,
|
|
@@ -297,6 +298,7 @@ Common.Settings.registerSettingExtension({
|
|
|
297
298
|
|
|
298
299
|
Common.Settings.registerSettingExtension({
|
|
299
300
|
category: Common.Settings.SettingCategory.NETWORK,
|
|
301
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
300
302
|
title: i18nLazyString(UIStrings.groupNetworkLogByFrame),
|
|
301
303
|
settingName: 'network.group-by-frame',
|
|
302
304
|
settingType: Common.Settings.SettingType.BOOLEAN,
|
|
@@ -162,6 +162,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
162
162
|
|
|
163
163
|
Common.Settings.registerSettingExtension({
|
|
164
164
|
category: Common.Settings.SettingCategory.PERFORMANCE,
|
|
165
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
165
166
|
title: i18nLazyString(UIStrings.showNativeFunctions),
|
|
166
167
|
settingName: 'showNativeFunctionsInJSProfile',
|
|
167
168
|
settingType: Common.Settings.SettingType.BOOLEAN,
|
|
@@ -154,6 +154,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
154
154
|
});
|
|
155
155
|
|
|
156
156
|
Common.Settings.registerSettingExtension({
|
|
157
|
+
storageType: Common.Settings.SettingStorageType.Synced,
|
|
157
158
|
settingName: 'emulation.locations',
|
|
158
159
|
settingType: Common.Settings.SettingType.ARRAY,
|
|
159
160
|
// TODO(crbug.com/1136655): http://crrev.com/c/2666426 regressed localization of city titles.
|
|
@@ -82,6 +82,10 @@ const UIStrings = {
|
|
|
82
82
|
*@description A context menu item in the Call Stack Sidebar Pane of the Sources panel
|
|
83
83
|
*/
|
|
84
84
|
addAllContentScriptsToIgnoreList: 'Add all content scripts to ignore list',
|
|
85
|
+
/**
|
|
86
|
+
*@description Text in Call Stack Sidebar Pane of the Sources panel when some call frames have warnings
|
|
87
|
+
*/
|
|
88
|
+
callFrameWarnings: 'Some call frames have warnings',
|
|
85
89
|
};
|
|
86
90
|
const str_ = i18n.i18n.registerUIStrings('panels/sources/CallStackSidebarPane.ts', UIStrings);
|
|
87
91
|
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
@@ -92,6 +96,7 @@ export class CallStackSidebarPane extends UI.View.SimpleView implements UI.Conte
|
|
|
92
96
|
UI.ListControl.ListDelegate<Item> {
|
|
93
97
|
private readonly ignoreListMessageElement: Element;
|
|
94
98
|
private readonly notPausedMessageElement: HTMLElement;
|
|
99
|
+
private readonly callFrameWarningsElement: HTMLElement;
|
|
95
100
|
private readonly items: UI.ListModel.ListModel<Item>;
|
|
96
101
|
private list: UI.ListControl.ListControl<Item>;
|
|
97
102
|
private readonly showMoreMessageElement: Element;
|
|
@@ -113,6 +118,12 @@ export class CallStackSidebarPane extends UI.View.SimpleView implements UI.Conte
|
|
|
113
118
|
this.notPausedMessageElement.textContent = i18nString(UIStrings.notPaused);
|
|
114
119
|
this.notPausedMessageElement.tabIndex = -1;
|
|
115
120
|
|
|
121
|
+
this.callFrameWarningsElement = this.contentElement.createChild('div', 'ignore-listed-message');
|
|
122
|
+
const icon = UI.Icon.Icon.create('smallicon-warning', 'call-frame-warning-icon');
|
|
123
|
+
this.callFrameWarningsElement.appendChild(icon);
|
|
124
|
+
this.callFrameWarningsElement.appendChild(document.createTextNode(i18nString(UIStrings.callFrameWarnings)));
|
|
125
|
+
this.callFrameWarningsElement.tabIndex = -1;
|
|
126
|
+
|
|
116
127
|
this.items = new UI.ListModel.ListModel();
|
|
117
128
|
this.list = new UI.ListControl.ListControl(this.items, this, UI.ListControl.ListMode.NonViewport);
|
|
118
129
|
this.contentElement.appendChild(this.list.element);
|
|
@@ -164,6 +175,8 @@ export class CallStackSidebarPane extends UI.View.SimpleView implements UI.Conte
|
|
|
164
175
|
private async doUpdate(): Promise<void> {
|
|
165
176
|
this.locationPool.disposeAll();
|
|
166
177
|
|
|
178
|
+
this.callFrameWarningsElement.classList.add('hidden');
|
|
179
|
+
|
|
167
180
|
const details = UI.Context.Context.instance().flavor(SDK.DebuggerModel.DebuggerPausedDetails);
|
|
168
181
|
if (!details) {
|
|
169
182
|
this.notPausedMessageElement.classList.remove('hidden');
|
|
@@ -178,6 +191,7 @@ export class CallStackSidebarPane extends UI.View.SimpleView implements UI.Conte
|
|
|
178
191
|
this.notPausedMessageElement.classList.add('hidden');
|
|
179
192
|
|
|
180
193
|
const itemPromises = [];
|
|
194
|
+
const uniqueWarnings: Set<string> = new Set();
|
|
181
195
|
for (const frame of details.callFrames) {
|
|
182
196
|
const itemPromise =
|
|
183
197
|
Item.createForDebuggerCallFrame(frame, this.locationPool, this.refreshItem.bind(this)).then(item => {
|
|
@@ -185,8 +199,15 @@ export class CallStackSidebarPane extends UI.View.SimpleView implements UI.Conte
|
|
|
185
199
|
return item;
|
|
186
200
|
});
|
|
187
201
|
itemPromises.push(itemPromise);
|
|
202
|
+
for (const warning of frame.warnings) {
|
|
203
|
+
uniqueWarnings.add(warning);
|
|
204
|
+
}
|
|
188
205
|
}
|
|
189
206
|
const items = await Promise.all(itemPromises);
|
|
207
|
+
if (uniqueWarnings.size) {
|
|
208
|
+
this.callFrameWarningsElement.classList.remove('hidden');
|
|
209
|
+
UI.Tooltip.Tooltip.install(this.callFrameWarningsElement, Array.from(uniqueWarnings).join('\n'));
|
|
210
|
+
}
|
|
190
211
|
|
|
191
212
|
let asyncStackTrace: Protocol.Runtime.StackTrace|null|undefined = details.asyncStackTrace;
|
|
192
213
|
if (!asyncStackTrace && details.asyncStackTraceId) {
|