chrome-devtools-frontend 1.0.1367881 → 1.0.1376716

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1157) hide show
  1. package/.vscode/extensions.json +4 -4
  2. package/config/gni/devtools_grd_files.gni +30 -8
  3. package/config/gni/devtools_image_files.gni +3 -0
  4. package/docs/README.md +1 -5
  5. package/docs/checklist/javascript.md +45 -8
  6. package/docs/contributing/design.md +1 -1
  7. package/docs/contributing/settings-experiments-features.md +1 -1
  8. package/docs/cookbook/README.md +12 -0
  9. package/docs/cookbook/create_new_issues.md +91 -0
  10. package/docs/cookbook/dependencies.md +103 -0
  11. package/docs/cookbook/localization.md +320 -0
  12. package/docs/cookbook/navbar.md +8 -0
  13. package/docs/cookbook/release_management.md +60 -0
  14. package/docs/cookbook/uma_metrics.md +121 -0
  15. package/docs/dependencies.md +1 -100
  16. package/docs/l10n.md +1 -295
  17. package/docs/release_management.md +1 -53
  18. package/extensions/cxx_debugging/e2e/standalone/MemoryInspector_test.ts +1 -1
  19. package/extensions/cxx_debugging/e2e/tsconfig.json +1 -0
  20. package/extensions/cxx_debugging/src/ExtensionOptions.ts +6 -7
  21. package/extensions/cxx_debugging/tests/CreditsItem_test.ts +4 -4
  22. package/front_end/.eslintrc.js +0 -1
  23. package/front_end/Images/src/center-focus-weak.svg +1 -0
  24. package/front_end/Images/src/history.svg +3 -0
  25. package/front_end/Images/src/home.svg +1 -0
  26. package/front_end/core/common/Color.ts +10 -0
  27. package/front_end/core/common/ResourceType.test.ts +26 -26
  28. package/front_end/core/common/ResourceType.ts +21 -12
  29. package/front_end/core/common/Revealer.ts +5 -0
  30. package/front_end/core/common/Settings.ts +5 -1
  31. package/front_end/core/host/AidaClient.ts +58 -0
  32. package/front_end/core/host/InspectorFrontendHost.ts +1 -1
  33. package/front_end/core/host/InspectorFrontendHostAPI.ts +8 -1
  34. package/front_end/core/host/UserMetrics.ts +16 -13
  35. package/front_end/core/i18n/locales/af.json +598 -109
  36. package/front_end/core/i18n/locales/am.json +607 -118
  37. package/front_end/core/i18n/locales/ar.json +888 -399
  38. package/front_end/core/i18n/locales/as.json +603 -114
  39. package/front_end/core/i18n/locales/az.json +606 -117
  40. package/front_end/core/i18n/locales/be.json +599 -110
  41. package/front_end/core/i18n/locales/bg.json +598 -109
  42. package/front_end/core/i18n/locales/bn.json +609 -120
  43. package/front_end/core/i18n/locales/bs.json +607 -118
  44. package/front_end/core/i18n/locales/ca.json +601 -112
  45. package/front_end/core/i18n/locales/cs.json +605 -116
  46. package/front_end/core/i18n/locales/cy.json +603 -114
  47. package/front_end/core/i18n/locales/da.json +599 -110
  48. package/front_end/core/i18n/locales/de.json +604 -115
  49. package/front_end/core/i18n/locales/el.json +596 -107
  50. package/front_end/core/i18n/locales/en-GB.json +599 -110
  51. package/front_end/core/i18n/locales/es-419.json +600 -111
  52. package/front_end/core/i18n/locales/es.json +602 -113
  53. package/front_end/core/i18n/locales/et.json +601 -112
  54. package/front_end/core/i18n/locales/eu.json +605 -116
  55. package/front_end/core/i18n/locales/fa.json +609 -120
  56. package/front_end/core/i18n/locales/fi.json +598 -109
  57. package/front_end/core/i18n/locales/fil.json +605 -116
  58. package/front_end/core/i18n/locales/fr-CA.json +602 -113
  59. package/front_end/core/i18n/locales/fr.json +600 -111
  60. package/front_end/core/i18n/locales/gl.json +595 -106
  61. package/front_end/core/i18n/locales/gu.json +605 -116
  62. package/front_end/core/i18n/locales/he.json +603 -114
  63. package/front_end/core/i18n/locales/hi.json +600 -111
  64. package/front_end/core/i18n/locales/hr.json +600 -111
  65. package/front_end/core/i18n/locales/hu.json +600 -111
  66. package/front_end/core/i18n/locales/hy.json +599 -110
  67. package/front_end/core/i18n/locales/id.json +603 -114
  68. package/front_end/core/i18n/locales/is.json +598 -109
  69. package/front_end/core/i18n/locales/it.json +602 -113
  70. package/front_end/core/i18n/locales/ja.json +596 -107
  71. package/front_end/core/i18n/locales/ka.json +597 -108
  72. package/front_end/core/i18n/locales/kk.json +884 -395
  73. package/front_end/core/i18n/locales/km.json +605 -116
  74. package/front_end/core/i18n/locales/kn.json +606 -117
  75. package/front_end/core/i18n/locales/ko.json +591 -102
  76. package/front_end/core/i18n/locales/ky.json +599 -110
  77. package/front_end/core/i18n/locales/lo.json +608 -119
  78. package/front_end/core/i18n/locales/lt.json +597 -108
  79. package/front_end/core/i18n/locales/lv.json +606 -117
  80. package/front_end/core/i18n/locales/mk.json +885 -396
  81. package/front_end/core/i18n/locales/ml.json +601 -112
  82. package/front_end/core/i18n/locales/mn.json +599 -110
  83. package/front_end/core/i18n/locales/mr.json +601 -112
  84. package/front_end/core/i18n/locales/ms.json +602 -113
  85. package/front_end/core/i18n/locales/my.json +604 -115
  86. package/front_end/core/i18n/locales/ne.json +609 -120
  87. package/front_end/core/i18n/locales/nl.json +597 -108
  88. package/front_end/core/i18n/locales/no.json +601 -112
  89. package/front_end/core/i18n/locales/or.json +601 -112
  90. package/front_end/core/i18n/locales/pa.json +600 -111
  91. package/front_end/core/i18n/locales/pl.json +601 -112
  92. package/front_end/core/i18n/locales/pt-PT.json +600 -111
  93. package/front_end/core/i18n/locales/pt.json +596 -107
  94. package/front_end/core/i18n/locales/ro.json +601 -112
  95. package/front_end/core/i18n/locales/ru.json +609 -120
  96. package/front_end/core/i18n/locales/si.json +603 -114
  97. package/front_end/core/i18n/locales/sk.json +599 -110
  98. package/front_end/core/i18n/locales/sl.json +601 -112
  99. package/front_end/core/i18n/locales/sq.json +602 -113
  100. package/front_end/core/i18n/locales/sr-Latn.json +598 -109
  101. package/front_end/core/i18n/locales/sr.json +598 -109
  102. package/front_end/core/i18n/locales/sv.json +600 -111
  103. package/front_end/core/i18n/locales/sw.json +606 -117
  104. package/front_end/core/i18n/locales/ta.json +892 -403
  105. package/front_end/core/i18n/locales/te.json +604 -115
  106. package/front_end/core/i18n/locales/th.json +597 -108
  107. package/front_end/core/i18n/locales/tr.json +601 -112
  108. package/front_end/core/i18n/locales/uk.json +598 -109
  109. package/front_end/core/i18n/locales/ur.json +604 -115
  110. package/front_end/core/i18n/locales/uz.json +599 -110
  111. package/front_end/core/i18n/locales/vi.json +602 -113
  112. package/front_end/core/i18n/locales/zh-HK.json +599 -110
  113. package/front_end/core/i18n/locales/zh-TW.json +595 -106
  114. package/front_end/core/i18n/locales/zh.json +601 -112
  115. package/front_end/core/i18n/locales/zu.json +607 -118
  116. package/front_end/core/root/Runtime.ts +15 -7
  117. package/front_end/{panels/animation → core/sdk}/AnimationModel.test.ts +85 -6
  118. package/front_end/{panels/animation → core/sdk}/AnimationModel.ts +302 -36
  119. package/front_end/core/sdk/CSSContainerQuery.ts +4 -2
  120. package/front_end/core/sdk/CSSMatchedStyles.test.ts +4 -0
  121. package/front_end/core/sdk/CSSMatchedStyles.ts +13 -10
  122. package/front_end/core/sdk/CSSMetadata.ts +6 -0
  123. package/front_end/core/sdk/CSSStyleDeclaration.test.ts +10 -0
  124. package/front_end/core/sdk/CSSStyleDeclaration.ts +1 -1
  125. package/front_end/core/sdk/DOMModel.ts +3 -3
  126. package/front_end/core/sdk/DebuggerModel.test.ts +2 -0
  127. package/front_end/core/sdk/EmulationModel.ts +32 -0
  128. package/front_end/core/sdk/EnhancedTracesParser.test.ts +4 -4
  129. package/front_end/core/sdk/EnhancedTracesParser.ts +4 -5
  130. package/front_end/core/sdk/RehydratingConnection.test.ts +190 -0
  131. package/front_end/core/sdk/RehydratingConnection.ts +310 -0
  132. package/front_end/core/sdk/RehydratingObject.ts +26 -2
  133. package/front_end/core/sdk/RuntimeModel.ts +31 -0
  134. package/front_end/core/sdk/Script.ts +1 -1
  135. package/front_end/core/sdk/TraceObject.ts +8 -0
  136. package/front_end/core/sdk/sdk.ts +2 -0
  137. package/front_end/devtools_compatibility.js +0 -1
  138. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +95 -74
  139. package/front_end/entrypoints/main/MainImpl.ts +10 -0
  140. package/front_end/generated/InspectorBackendCommands.js +10 -9
  141. package/front_end/generated/SupportedCSSProperties.js +15 -1
  142. package/front_end/generated/protocol-mapping.d.ts +4 -3
  143. package/front_end/generated/protocol-proxy-api.d.ts +4 -3
  144. package/front_end/generated/protocol.ts +31 -2
  145. package/front_end/legacy_test_runner/network_test_runner/network_test_runner.js +1 -0
  146. package/front_end/models/har/HARFormat.ts +1 -0
  147. package/front_end/models/har/Importer.test.ts +16 -2
  148. package/front_end/models/har/Importer.ts +2 -2
  149. package/front_end/models/har/Log.test.ts +23 -0
  150. package/front_end/models/har/Log.ts +6 -4
  151. package/front_end/models/heap_snapshot_model/HeapSnapshotModel.ts +4 -2
  152. package/front_end/models/issues_manager/AttributionReportingIssue.ts +58 -18
  153. package/front_end/models/issues_manager/CookieIssue.ts +12 -0
  154. package/front_end/models/issues_manager/descriptions/arInvalidInfoHeader.md +5 -0
  155. package/front_end/models/issues_manager/descriptions/arNavigationRegistrationUniqueScopeAlreadySet.md +5 -0
  156. package/front_end/models/issues_manager/descriptions/arNoRegisterOsSourceHeader.md +5 -0
  157. package/front_end/models/issues_manager/descriptions/arNoRegisterOsTriggerHeader.md +5 -0
  158. package/front_end/models/issues_manager/descriptions/arNoRegisterSourceHeader.md +5 -0
  159. package/front_end/models/issues_manager/descriptions/arNoRegisterTriggerHeader.md +5 -0
  160. package/front_end/models/issues_manager/descriptions/arNoWebOrOsSupport.md +4 -0
  161. package/front_end/models/issues_manager/descriptions/placeholderDescriptionForInvisibleIssues.md +3 -0
  162. package/front_end/models/javascript_metadata/NativeFunctions.js +69 -18
  163. package/front_end/models/live-metrics/LiveMetrics.ts +116 -19
  164. package/front_end/models/live-metrics/web-vitals-injected/OnEachInteraction.ts +24 -61
  165. package/front_end/models/live-metrics/web-vitals-injected/spec/spec.ts +49 -21
  166. package/front_end/models/live-metrics/web-vitals-injected/web-vitals-injected.ts +43 -5
  167. package/front_end/models/timeline_model/TimelineModelFilter.ts +2 -2
  168. package/front_end/models/trace/Processor.ts +5 -1
  169. package/front_end/models/trace/extras/ThirdParties.test.ts +117 -0
  170. package/front_end/models/trace/extras/ThirdParties.ts +207 -0
  171. package/front_end/models/trace/extras/extras.ts +1 -0
  172. package/front_end/models/trace/handlers/FramesHandler.ts +12 -5
  173. package/front_end/models/trace/handlers/InitiatorsHandler.test.ts +40 -0
  174. package/front_end/models/trace/handlers/InitiatorsHandler.ts +9 -0
  175. package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +17 -0
  176. package/front_end/models/trace/handlers/NetworkRequestsHandler.ts +2 -2
  177. package/front_end/models/trace/handlers/RendererHandler.test.ts +4 -4
  178. package/front_end/models/trace/helpers/Timing.test.ts +29 -0
  179. package/front_end/models/trace/helpers/Timing.ts +18 -0
  180. package/front_end/models/trace/helpers/TreeHelpers.test.ts +52 -34
  181. package/front_end/models/trace/helpers/TreeHelpers.ts +135 -45
  182. package/front_end/models/trace/insights/CumulativeLayoutShift.test.ts +22 -0
  183. package/front_end/models/trace/insights/CumulativeLayoutShift.ts +62 -20
  184. package/front_end/models/trace/insights/ThirdPartyWeb.ts +13 -183
  185. package/front_end/models/trace/lantern/core/NetworkAnalyzer.test.ts +4 -4
  186. package/front_end/models/trace/lantern/core/NetworkAnalyzer.ts +9 -5
  187. package/front_end/models/trace/lantern/simulation/Simulator.ts +1 -1
  188. package/front_end/models/trace/lantern/testing/MetricTestUtils.ts +4 -0
  189. package/front_end/models/trace/types/TraceEvents.ts +68 -2
  190. package/front_end/panels/accessibility/AccessibilitySidebarView.ts +1 -1
  191. package/front_end/panels/animation/AnimationGroupPreviewUI.ts +3 -3
  192. package/front_end/panels/animation/AnimationTimeline.test.ts +15 -15
  193. package/front_end/panels/animation/AnimationTimeline.ts +85 -53
  194. package/front_end/panels/animation/AnimationUI.ts +5 -6
  195. package/front_end/panels/animation/animation-meta.ts +15 -0
  196. package/front_end/panels/animation/animation.ts +0 -4
  197. package/front_end/panels/application/ApplicationPanelSidebar.test.ts +16 -0
  198. package/front_end/panels/application/ApplicationPanelSidebar.ts +13 -9
  199. package/front_end/panels/application/ExtensionStorageItemsView.test.ts +72 -0
  200. package/front_end/panels/application/ExtensionStorageItemsView.ts +23 -1
  201. package/front_end/panels/application/ExtensionStorageModel.test.ts +15 -0
  202. package/front_end/panels/application/ExtensionStorageModel.ts +10 -1
  203. package/front_end/panels/application/OpenedWindowDetailsView.ts +2 -3
  204. package/front_end/panels/application/SharedStorageItemsView.test.ts +1 -20
  205. package/front_end/panels/application/components/BackForwardCacheStrings.ts +1 -0
  206. package/front_end/panels/application/components/BounceTrackingMitigationsView.ts +3 -7
  207. package/front_end/panels/application/components/EndpointsGrid.ts +1 -2
  208. package/front_end/panels/application/components/FrameDetailsView.ts +8 -8
  209. package/front_end/panels/application/components/InterestGroupAccessGrid.ts +4 -8
  210. package/front_end/panels/application/components/PermissionsPolicySection.ts +3 -4
  211. package/front_end/panels/application/components/ReportsGrid.ts +2 -4
  212. package/front_end/panels/application/components/SharedStorageAccessGrid.ts +4 -9
  213. package/front_end/panels/application/components/StackTrace.ts +6 -9
  214. package/front_end/panels/application/components/StorageMetadataView.ts +1 -2
  215. package/front_end/panels/application/components/TrustTokensView.ts +1 -2
  216. package/front_end/panels/application/preloading/PreloadingView.ts +5 -5
  217. package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.test.ts +2 -2
  218. package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.ts +3 -9
  219. package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +2 -5
  220. package/front_end/panels/application/preloading/components/PreloadingDisabledInfobar.ts +2 -2
  221. package/front_end/panels/application/preloading/components/PreloadingGrid.test.ts +1 -1
  222. package/front_end/panels/application/preloading/components/PreloadingGrid.ts +3 -6
  223. package/front_end/panels/application/preloading/components/PreloadingMismatchedHeadersGrid.ts +1 -3
  224. package/front_end/panels/application/preloading/components/PreloadingString.ts +5 -0
  225. package/front_end/panels/application/preloading/components/RuleSetDetailsView.ts +2 -3
  226. package/front_end/panels/application/preloading/components/RuleSetGrid.ts +7 -10
  227. package/front_end/panels/autofill/AutofillView.ts +2 -5
  228. package/front_end/panels/console/ConsoleView.ts +1 -1
  229. package/front_end/panels/css_overview/components/CSSOverviewStartView.ts +3 -5
  230. package/front_end/panels/elements/AccessibilityTreeUtils.ts +4 -6
  231. package/front_end/panels/elements/CSSRuleValidator.ts +0 -5
  232. package/front_end/panels/elements/ColorSwatchPopoverIcon.ts +0 -2
  233. package/front_end/panels/elements/ElementStatePaneWidget.ts +5 -0
  234. package/front_end/panels/elements/ElementsPanel.ts +4 -4
  235. package/front_end/panels/elements/ElementsTreeElement.ts +1 -1
  236. package/front_end/panels/elements/StylePropertyTreeElement.test.ts +90 -0
  237. package/front_end/panels/elements/StylePropertyTreeElement.ts +29 -2
  238. package/front_end/panels/elements/components/ElementsBreadcrumbs.ts +3 -5
  239. package/front_end/panels/elements/components/LayoutPane.ts +2 -3
  240. package/front_end/panels/elements/components/QueryContainer.ts +3 -5
  241. package/front_end/panels/elements/stylePropertiesTreeOutline.css +13 -0
  242. package/front_end/panels/emulation/components/DeviceSizeInputElement.ts +0 -2
  243. package/front_end/panels/event_listeners/EventListenersView.ts +2 -2
  244. package/front_end/panels/event_listeners/eventListenersView.css +4 -3
  245. package/front_end/panels/explain/components/ConsoleInsight.test.ts +56 -8
  246. package/front_end/panels/explain/components/ConsoleInsight.ts +53 -36
  247. package/front_end/panels/explain/explain-meta.ts +1 -12
  248. package/front_end/panels/freestyler/AiAgent.test.ts +92 -12
  249. package/front_end/panels/freestyler/AiAgent.ts +341 -56
  250. package/front_end/panels/freestyler/DrJonesFileAgent.test.ts +70 -43
  251. package/front_end/panels/freestyler/DrJonesFileAgent.ts +75 -79
  252. package/front_end/panels/freestyler/DrJonesNetworkAgent.test.ts +135 -72
  253. package/front_end/panels/freestyler/DrJonesNetworkAgent.ts +219 -117
  254. package/front_end/panels/freestyler/DrJonesPerformanceAgent.test.ts +102 -56
  255. package/front_end/panels/freestyler/DrJonesPerformanceAgent.ts +118 -114
  256. package/front_end/panels/freestyler/FreestylerAgent.test.ts +108 -100
  257. package/front_end/panels/freestyler/FreestylerAgent.ts +65 -183
  258. package/front_end/panels/freestyler/FreestylerEvaluateAction.test.ts +40 -36
  259. package/front_end/panels/freestyler/FreestylerEvaluateAction.ts +15 -14
  260. package/front_end/panels/freestyler/FreestylerPanel.test.ts +548 -15
  261. package/front_end/panels/freestyler/FreestylerPanel.ts +385 -132
  262. package/front_end/panels/freestyler/components/FreestylerChatUi.test.ts +34 -4
  263. package/front_end/panels/freestyler/components/FreestylerChatUi.ts +186 -92
  264. package/front_end/panels/freestyler/components/UserActionRow.test.ts +60 -0
  265. package/front_end/panels/freestyler/components/{ProvideFeedback.ts → UserActionRow.ts} +42 -16
  266. package/front_end/panels/freestyler/components/freestylerChatUi.css +100 -97
  267. package/front_end/panels/freestyler/components/userActionRow.css +149 -0
  268. package/front_end/panels/freestyler/freestyler-meta.ts +50 -23
  269. package/front_end/panels/freestyler/freestyler.ts +1 -1
  270. package/front_end/panels/issues/AttributionReportingIssueDetailsView.ts +14 -0
  271. package/front_end/panels/issues/IssueAggregator.ts +10 -1
  272. package/front_end/panels/issues/components/ElementsPanelLink.ts +0 -1
  273. package/front_end/panels/issues/components/HideIssuesMenu.ts +12 -4
  274. package/front_end/panels/lighthouse/LighthouseStartView.ts +1 -1
  275. package/front_end/panels/linear_memory_inspector/LinearMemoryInspectorController.ts +2 -2
  276. package/front_end/panels/linear_memory_inspector/components/LinearMemoryHighlightChipList.ts +1 -2
  277. package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +7 -12
  278. package/front_end/panels/linear_memory_inspector/components/LinearMemoryValueInterpreter.ts +3 -4
  279. package/front_end/panels/linear_memory_inspector/components/ValueInterpreterDisplay.ts +1 -2
  280. package/front_end/panels/network/BinaryResourceView.ts +3 -2
  281. package/front_end/panels/network/NetworkDataGridNode.test.ts +29 -0
  282. package/front_end/panels/network/NetworkDataGridNode.ts +56 -5
  283. package/front_end/panels/network/NetworkLogView.test.ts +29 -0
  284. package/front_end/panels/network/NetworkLogView.ts +2 -2
  285. package/front_end/panels/network/NetworkPanel.test.ts +3 -22
  286. package/front_end/panels/network/NetworkPanel.ts +26 -7
  287. package/front_end/panels/network/NetworkWaterfallColumn.ts +2 -0
  288. package/front_end/panels/network/RequestResponseView.test.ts +2 -2
  289. package/front_end/panels/network/RequestResponseView.ts +6 -10
  290. package/front_end/panels/network/ResourceWebSocketFrameView.ts +3 -1
  291. package/front_end/panels/network/components/HeaderSectionRow.ts +11 -12
  292. package/front_end/panels/network/components/RequestHeaderSection.ts +4 -9
  293. package/front_end/panels/network/components/RequestHeadersView.css +7 -0
  294. package/front_end/panels/network/components/RequestTrustTokensView.ts +1 -1
  295. package/front_end/panels/network/network.ts +0 -2
  296. package/front_end/panels/network/networkConfigView.css +8 -7
  297. package/front_end/panels/network/networkLogView.css +32 -2
  298. package/front_end/panels/network/networkPanel.css +2 -1
  299. package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +11 -10
  300. package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +12 -8
  301. package/front_end/panels/profiler/HeapSnapshotProxy.ts +6 -6
  302. package/front_end/panels/protocol_monitor/components/JSONEditor.ts +5 -5
  303. package/front_end/panels/recorder/components/StartView.ts +4 -5
  304. package/front_end/panels/recorder/components/recordingView.css +1 -4
  305. package/front_end/panels/recorder/components/selectButton.css +6 -50
  306. package/front_end/panels/recorder/models/RecorderShortcutHelper.ts +1 -1
  307. package/front_end/panels/recorder/models/RecordingSession.ts +4 -4
  308. package/front_end/panels/recorder/recorderController.css +38 -18
  309. package/front_end/panels/screencast/ScreencastApp.ts +1 -1
  310. package/front_end/panels/screencast/ScreencastView.ts +1 -1
  311. package/front_end/panels/search/SearchView.ts +0 -2
  312. package/front_end/panels/search/searchView.css +5 -1
  313. package/front_end/panels/security/CookieReportTreeElement.ts +26 -0
  314. package/front_end/panels/security/OriginTreeElement.ts +20 -7
  315. package/front_end/panels/security/SecurityPanel.ts +64 -15
  316. package/front_end/panels/security/{SecurityAndPrivacyPanelSidebar.ts → SecurityPanelSidebar.ts} +24 -13
  317. package/front_end/panels/security/SecurityPanelSidebarTreeElement.ts +1 -12
  318. package/front_end/panels/security/sidebar.css +40 -1
  319. package/front_end/panels/sensors/SensorsView.ts +27 -0
  320. package/front_end/panels/sensors/sensors-meta.ts +59 -0
  321. package/front_end/panels/settings/AISettingsTab.test.ts +79 -11
  322. package/front_end/panels/settings/AISettingsTab.ts +109 -22
  323. package/front_end/panels/settings/FrameworkIgnoreListSettingsTab.ts +44 -30
  324. package/front_end/panels/settings/KeybindsSettingsTab.ts +34 -17
  325. package/front_end/panels/settings/SettingsScreen.ts +1 -1
  326. package/front_end/panels/settings/aiSettingsTab.css +13 -0
  327. package/front_end/panels/settings/components/SyncSection.ts +1 -3
  328. package/front_end/panels/settings/emulation/DevicesSettingsTab.ts +51 -29
  329. package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +24 -12
  330. package/front_end/panels/settings/emulation/devicesSettingsTab.css +11 -10
  331. package/front_end/panels/settings/frameworkIgnoreListSettingsTab.css +14 -42
  332. package/front_end/panels/settings/keybindsSettingsTab.css +51 -89
  333. package/front_end/panels/settings/settingsScreen.css +30 -6
  334. package/front_end/panels/sources/AddSourceMapURLDialog.ts +1 -1
  335. package/front_end/panels/sources/CSSPlugin.ts +0 -2
  336. package/front_end/panels/sources/NavigatorView.ts +31 -23
  337. package/front_end/panels/sources/SourcesPanel.ts +25 -6
  338. package/front_end/panels/sources/SourcesView.test.ts +1 -0
  339. package/front_end/panels/sources/SourcesView.ts +2 -2
  340. package/front_end/panels/sources/components/BreakpointsView.ts +0 -1
  341. package/front_end/panels/sources/components/HeadersView.ts +0 -1
  342. package/front_end/panels/sources/navigatorTree.css +11 -0
  343. package/front_end/panels/timeline/AnnotationHelpers.ts +3 -3
  344. package/front_end/panels/timeline/AppenderUtils.ts +1 -3
  345. package/front_end/panels/timeline/CompatibilityTracksAppender.ts +21 -9
  346. package/front_end/panels/timeline/EntriesFilter.test.ts +19 -36
  347. package/front_end/panels/timeline/EntriesFilter.ts +6 -4
  348. package/front_end/panels/timeline/EventsTimelineTreeView.ts +9 -9
  349. package/front_end/panels/timeline/InteractionsTrackAppender.ts +2 -1
  350. package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +6 -6
  351. package/front_end/panels/timeline/NetworkTrackAppender.ts +1 -8
  352. package/front_end/panels/timeline/ThreadAppender.ts +5 -6
  353. package/front_end/panels/timeline/TimelineDetailsView.test.ts +85 -42
  354. package/front_end/panels/timeline/TimelineDetailsView.ts +71 -42
  355. package/front_end/panels/timeline/TimelineEventOverview.ts +10 -10
  356. package/front_end/panels/timeline/TimelineFilters.test.ts +4 -4
  357. package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +58 -62
  358. package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +16 -15
  359. package/front_end/panels/timeline/TimelineFlameChartView.test.ts +2 -3
  360. package/front_end/panels/timeline/TimelineFlameChartView.ts +102 -57
  361. package/front_end/panels/timeline/TimelineHistoryManager.ts +4 -0
  362. package/front_end/panels/timeline/TimelineMiniMap.ts +0 -8
  363. package/front_end/panels/timeline/TimelinePanel.ts +89 -44
  364. package/front_end/panels/timeline/TimelineSelection.test.ts +91 -36
  365. package/front_end/panels/timeline/TimelineSelection.ts +48 -60
  366. package/front_end/panels/timeline/TimelineSelectorStatsView.ts +3 -8
  367. package/front_end/panels/timeline/TimelineTreeView.ts +7 -5
  368. package/front_end/panels/timeline/TimelineUIUtils.test.ts +51 -4
  369. package/front_end/panels/timeline/TimelineUIUtils.ts +37 -27
  370. package/front_end/panels/timeline/UIDevtoolsController.ts +5 -5
  371. package/front_end/panels/timeline/UIDevtoolsUtils.ts +59 -68
  372. package/front_end/panels/timeline/components/BreadcrumbsUI.ts +2 -3
  373. package/front_end/panels/timeline/components/LayoutShiftDetails.ts +25 -8
  374. package/front_end/panels/timeline/components/LiveMetricsView.test.ts +230 -68
  375. package/front_end/panels/timeline/components/LiveMetricsView.ts +146 -112
  376. package/front_end/panels/timeline/components/NetworkRequestDetails.test.ts +14 -7
  377. package/front_end/panels/timeline/components/NetworkRequestDetails.ts +47 -117
  378. package/front_end/panels/timeline/components/NetworkRequestTooltip.ts +64 -74
  379. package/front_end/panels/timeline/components/Sidebar.ts +2 -1
  380. package/front_end/panels/timeline/components/SidebarAnnotationsTab.ts +11 -13
  381. package/front_end/panels/timeline/components/SidebarInsightsTab.ts +51 -2
  382. package/front_end/panels/timeline/components/SidebarSingleInsightSet.test.ts +1 -2
  383. package/front_end/panels/timeline/components/Utils.ts +28 -29
  384. package/front_end/panels/timeline/components/components.ts +0 -4
  385. package/front_end/panels/timeline/components/insights/CLSCulprits.ts +10 -3
  386. package/front_end/panels/timeline/components/insights/DocumentLatency.ts +8 -4
  387. package/front_end/panels/timeline/components/insights/EventRef.ts +0 -1
  388. package/front_end/panels/timeline/components/insights/FontDisplay.ts +1 -1
  389. package/front_end/panels/timeline/components/insights/Helpers.ts +4 -4
  390. package/front_end/panels/timeline/components/insights/InteractionToNextPaint.ts +3 -5
  391. package/front_end/panels/timeline/components/insights/LCPDiscovery.ts +1 -1
  392. package/front_end/panels/timeline/components/insights/LCPPhases.ts +7 -1
  393. package/front_end/panels/timeline/components/insights/NodeLink.ts +0 -1
  394. package/front_end/panels/timeline/components/insights/README.md +2 -2
  395. package/front_end/panels/timeline/components/insights/RenderBlocking.ts +5 -7
  396. package/front_end/panels/timeline/components/insights/SidebarInsight.ts +14 -5
  397. package/front_end/panels/timeline/components/insights/SlowCSSSelector.ts +112 -34
  398. package/front_end/panels/timeline/components/insights/Table.ts +1 -3
  399. package/front_end/panels/timeline/components/insights/ThirdParties.ts +6 -9
  400. package/front_end/panels/timeline/components/insights/Viewport.ts +3 -5
  401. package/front_end/panels/timeline/components/layoutShiftDetails.css +7 -1
  402. package/front_end/panels/timeline/components/liveMetricsView.css +59 -18
  403. package/front_end/panels/timeline/components/networkRequestDetails.css +9 -49
  404. package/front_end/panels/timeline/components/networkRequestTooltip.css +34 -11
  405. package/front_end/panels/timeline/components/relatedInsightChips.css +1 -1
  406. package/front_end/panels/timeline/components/sidebarInsightsTab.css +20 -0
  407. package/front_end/panels/timeline/extensions/ExtensionUI.ts +7 -7
  408. package/front_end/panels/timeline/fixtures/traces/README.md +4 -0
  409. package/front_end/panels/timeline/fixtures/traces/scheduler-post-task.json.gz +0 -0
  410. package/front_end/panels/timeline/fixtures/traces/unsized-images.json.gz +0 -0
  411. package/front_end/panels/timeline/historyToolbarButton.css +33 -19
  412. package/front_end/panels/timeline/overlays/OverlaysImpl.test.ts +0 -16
  413. package/front_end/panels/timeline/overlays/OverlaysImpl.ts +48 -22
  414. package/front_end/panels/timeline/overlays/components/entriesLinkOverlay.css +8 -0
  415. package/front_end/panels/timeline/overlays/components/entryLabelOverlay.css +16 -0
  416. package/front_end/panels/timeline/timeline-meta.ts +11 -0
  417. package/front_end/panels/timeline/timelineFlameChartView.css +16 -0
  418. package/front_end/panels/timeline/track_appenders/AnimationsTrackAppender.test.ts +2 -3
  419. package/front_end/panels/timeline/track_appenders/AppenderUtils.test.ts +1 -6
  420. package/front_end/panels/timeline/track_appenders/CompatibilityTracksAppender.test.ts +1 -1
  421. package/front_end/panels/timeline/track_appenders/ExtensionTrackAppender.test.ts +7 -8
  422. package/front_end/panels/timeline/track_appenders/GPUTrackAppender.test.ts +2 -2
  423. package/front_end/panels/timeline/track_appenders/InteractionsTrackAppender.test.ts +3 -3
  424. package/front_end/panels/timeline/track_appenders/LayoutShiftsTrackAppender.test.ts +3 -4
  425. package/front_end/panels/timeline/track_appenders/ServerTimingsTrackAppender.test.ts +2 -3
  426. package/front_end/panels/timeline/track_appenders/ThreadAppender.test.ts +5 -10
  427. package/front_end/panels/timeline/track_appenders/TimingsTrackAppender.test.ts +5 -5
  428. package/front_end/panels/timeline/utils/AICallTree.test.ts +80 -0
  429. package/front_end/panels/timeline/utils/AICallTree.ts +165 -0
  430. package/front_end/panels/timeline/{components → utils}/EntryName.test.ts +12 -12
  431. package/front_end/panels/timeline/{components → utils}/EntryName.ts +1 -1
  432. package/front_end/panels/timeline/{components → utils}/EntryStyles.ts +28 -1
  433. package/front_end/panels/timeline/utils/Helpers.test.ts +8 -3
  434. package/front_end/panels/timeline/utils/Helpers.ts +3 -4
  435. package/front_end/panels/timeline/utils/IgnoreList.test.ts +86 -0
  436. package/front_end/panels/timeline/utils/IgnoreList.ts +11 -4
  437. package/front_end/panels/timeline/utils/NetworkRequest.ts +1 -1
  438. package/front_end/panels/timeline/utils/SourceMapsResolver.test.ts +51 -18
  439. package/front_end/panels/timeline/utils/SourceMapsResolver.ts +3 -1
  440. package/front_end/panels/timeline/utils/utils.ts +6 -0
  441. package/front_end/panels/utils/utils.ts +56 -4
  442. package/front_end/services/trace_bounds/TraceBounds.ts +7 -1
  443. package/front_end/testing/ContextMenuHelpers.ts +1 -1
  444. package/front_end/testing/EnvironmentHelpers.ts +25 -3
  445. package/front_end/testing/NetworkHelpers.ts +38 -0
  446. package/front_end/testing/StorageItemsViewHelpers.ts +24 -0
  447. package/front_end/testing/TraceHelpers.ts +10 -0
  448. package/front_end/third_party/additional_readme_paths.json +1 -0
  449. package/front_end/third_party/codemirror.next/chunk/angular.js +1 -1
  450. package/front_end/third_party/codemirror.next/chunk/angular.js.map +1 -1
  451. package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
  452. package/front_end/third_party/codemirror.next/chunk/codemirror.js.map +1 -1
  453. package/front_end/third_party/codemirror.next/chunk/cpp.js.map +1 -1
  454. package/front_end/third_party/codemirror.next/chunk/legacy.js.map +1 -1
  455. package/front_end/third_party/codemirror.next/chunk/less.js.map +1 -1
  456. package/front_end/third_party/codemirror.next/chunk/markdown.js +1 -1
  457. package/front_end/third_party/codemirror.next/chunk/markdown.js.map +1 -1
  458. package/front_end/third_party/codemirror.next/chunk/php.js.map +1 -1
  459. package/front_end/third_party/codemirror.next/chunk/python.js +1 -1
  460. package/front_end/third_party/codemirror.next/chunk/python.js.map +1 -1
  461. package/front_end/third_party/codemirror.next/chunk/sass.js.map +1 -1
  462. package/front_end/third_party/codemirror.next/chunk/svelte.js +1 -1
  463. package/front_end/third_party/codemirror.next/chunk/svelte.js.map +1 -1
  464. package/front_end/third_party/codemirror.next/chunk/vue.js +1 -1
  465. package/front_end/third_party/codemirror.next/chunk/vue.js.map +1 -1
  466. package/front_end/third_party/codemirror.next/chunk/xml.js +1 -1
  467. package/front_end/third_party/codemirror.next/chunk/xml.js.map +1 -1
  468. package/front_end/third_party/codemirror.next/codemirror.next.d.ts +68 -3
  469. package/front_end/third_party/codemirror.next/codemirror.next.js +1 -1
  470. package/front_end/third_party/codemirror.next/package.json +2 -1
  471. package/front_end/third_party/intl-messageformat/README.chromium +2 -1
  472. package/front_end/third_party/intl-messageformat/package/intl-messageformat.esm.js +0 -1
  473. package/front_end/third_party/json5/LICENSE +23 -0
  474. package/front_end/third_party/json5/README.chromium +17 -0
  475. package/front_end/third_party/json5/json5-tsconfig.json +8 -0
  476. package/front_end/third_party/json5/json5.ts +4 -0
  477. package/front_end/third_party/json5/lib/index.d.ts +2 -0
  478. package/front_end/third_party/json5/lib/index.js +1121 -0
  479. package/front_end/third_party/json5/package/lib/index.d.ts +4 -0
  480. package/front_end/third_party/json5/package/lib/index.js +9 -0
  481. package/front_end/third_party/json5/package/lib/parse.d.ts +15 -0
  482. package/front_end/third_party/json5/package/lib/parse.js +1114 -0
  483. package/front_end/third_party/json5/package/lib/register.js +13 -0
  484. package/front_end/third_party/json5/package/lib/require.js +4 -0
  485. package/front_end/third_party/json5/package/lib/stringify.d.ts +89 -0
  486. package/front_end/third_party/json5/package/lib/stringify.js +261 -0
  487. package/front_end/third_party/json5/package/lib/unicode.d.ts +3 -0
  488. package/front_end/third_party/json5/package/lib/unicode.js +4 -0
  489. package/front_end/third_party/json5/package/lib/util.d.ts +5 -0
  490. package/front_end/third_party/json5/package/lib/util.js +35 -0
  491. package/front_end/third_party/json5/package.json +8 -0
  492. package/front_end/third_party/json5/rebuild.sh +5 -0
  493. package/front_end/third_party/puppeteer/README.chromium +2 -2
  494. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.d.ts +2 -2
  495. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.d.ts.map +1 -1
  496. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.js +1 -6
  497. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.js.map +1 -1
  498. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/BrowserContext.d.ts +1 -1
  499. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/BrowserContext.js +1 -1
  500. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/CDPSession.d.ts +1 -1
  501. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/CDPSession.js +1 -1
  502. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts +4 -4
  503. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js +18 -11
  504. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js.map +1 -1
  505. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.d.ts +2 -2
  506. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.js +13 -6
  507. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.js.map +1 -1
  508. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.d.ts +7 -2
  509. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.d.ts.map +1 -1
  510. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.js +3 -3
  511. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.js.map +1 -1
  512. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPResponse.d.ts +0 -1
  513. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPResponse.d.ts.map +1 -1
  514. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Input.d.ts +3 -3
  515. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Input.js +1 -1
  516. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/JSHandle.js +12 -5
  517. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/JSHandle.js.map +1 -1
  518. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts +22 -22
  519. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts.map +1 -1
  520. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js +26 -19
  521. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js.map +1 -1
  522. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/WebWorker.d.ts +2 -2
  523. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/WebWorker.js +2 -2
  524. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/api.d.ts +1 -1
  525. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/api.d.ts.map +1 -1
  526. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/api.js +0 -1
  527. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/api.js.map +1 -1
  528. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/locators/locators.d.ts.map +1 -1
  529. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/locators/locators.js +12 -5
  530. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/locators/locators.js.map +1 -1
  531. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/BidiOverCdp.js +1 -2
  532. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/BidiOverCdp.js.map +1 -1
  533. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.d.ts +0 -1
  534. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.d.ts.map +1 -1
  535. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.js +4 -0
  536. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.js.map +1 -1
  537. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/BrowserConnector.js +1 -2
  538. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/BrowserConnector.js.map +1 -1
  539. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/BrowserContext.js +12 -5
  540. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/BrowserContext.js.map +1 -1
  541. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ElementHandle.js +12 -5
  542. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ElementHandle.js.map +1 -1
  543. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ExposedFunction.js +12 -5
  544. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ExposedFunction.js.map +1 -1
  545. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.d.ts.map +1 -1
  546. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.js +3 -0
  547. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.js.map +1 -1
  548. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js +21 -10
  549. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js.map +1 -1
  550. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Realm.js +12 -5
  551. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Realm.js.map +1 -1
  552. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js +12 -5
  553. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js.map +1 -1
  554. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/core.d.ts +1 -1
  555. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/core.d.ts.map +1 -1
  556. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/core.js +0 -1
  557. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/core.js.map +1 -1
  558. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/util.js +2 -3
  559. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/util.js.map +1 -1
  560. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/AriaQueryHandler.d.ts.map +1 -1
  561. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/AriaQueryHandler.js +3 -0
  562. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/AriaQueryHandler.js.map +1 -1
  563. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Binding.js +12 -5
  564. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Binding.js.map +1 -1
  565. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Browser.d.ts +0 -1
  566. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Browser.d.ts.map +1 -1
  567. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/BrowserConnector.js +1 -2
  568. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/BrowserConnector.js.map +1 -1
  569. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/BrowserContext.js +12 -5
  570. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/BrowserContext.js.map +1 -1
  571. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ChromeTargetManager.d.ts.map +1 -1
  572. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ChromeTargetManager.js +3 -1
  573. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ChromeTargetManager.js.map +1 -1
  574. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Connection.js +2 -2
  575. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Connection.js.map +1 -1
  576. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/DeviceRequestPrompt.d.ts +1 -1
  577. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/DeviceRequestPrompt.js +1 -1
  578. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExecutionContext.d.ts +3 -3
  579. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExecutionContext.d.ts.map +1 -1
  580. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExecutionContext.js +17 -13
  581. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExecutionContext.js.map +1 -1
  582. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExtensionTransport.d.ts.map +1 -1
  583. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExtensionTransport.js +5 -1
  584. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExtensionTransport.js.map +1 -1
  585. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/FrameManager.js +1 -1
  586. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/FrameManager.js.map +1 -1
  587. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPResponse.js +1 -1
  588. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPResponse.js.map +1 -1
  589. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Input.d.ts.map +1 -1
  590. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Input.js.map +1 -1
  591. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/IsolatedWorld.d.ts +1 -2
  592. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/IsolatedWorld.d.ts.map +1 -1
  593. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/IsolatedWorld.js.map +1 -1
  594. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/JSHandle.js +2 -2
  595. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/JSHandle.js.map +1 -1
  596. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.d.ts.map +1 -1
  597. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.js +2 -1
  598. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.js.map +1 -1
  599. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.d.ts +1 -1
  600. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.d.ts.map +1 -1
  601. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.js +16 -7
  602. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.js.map +1 -1
  603. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.d.ts +4 -4
  604. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.d.ts.map +1 -1
  605. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.js +4 -4
  606. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/cdp.d.ts +2 -0
  607. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/cdp.d.ts.map +1 -1
  608. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/cdp.js +2 -0
  609. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/cdp.js.map +1 -1
  610. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/utils.js +6 -6
  611. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/utils.js.map +1 -1
  612. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/BrowserConnector.js +1 -2
  613. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/BrowserConnector.js.map +1 -1
  614. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/CSSQueryHandler.d.ts.map +1 -1
  615. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/CallbackRegistry.d.ts.map +1 -1
  616. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/CallbackRegistry.js +2 -2
  617. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/CallbackRegistry.js.map +1 -1
  618. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/ConnectOptions.d.ts +3 -0
  619. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/ConnectOptions.d.ts.map +1 -1
  620. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Debug.d.ts.map +1 -1
  621. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Debug.js +4 -5
  622. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Debug.js.map +1 -1
  623. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/GetQueryHandler.js +1 -2
  624. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/GetQueryHandler.js.map +1 -1
  625. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HandleIterator.js +13 -7
  626. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HandleIterator.js.map +1 -1
  627. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LazyArg.d.ts +1 -1
  628. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LazyArg.d.ts.map +1 -1
  629. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/PSelectorParser.js +1 -2
  630. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/PSelectorParser.js.map +1 -1
  631. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/PierceQueryHandler.d.ts.map +1 -1
  632. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.js +12 -5
  633. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.js.map +1 -1
  634. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/common.d.ts +7 -7
  635. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/common.d.ts.map +1 -1
  636. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/common.js +0 -7
  637. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/common.js.map +1 -1
  638. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.d.ts +2 -3
  639. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.d.ts.map +1 -1
  640. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.js +14 -12
  641. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.js.map +1 -1
  642. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/environment.d.ts +0 -2
  643. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/environment.d.ts.map +1 -1
  644. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.d.ts +1 -1
  645. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.js +1 -1
  646. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/ARIAQuerySelector.d.ts.map +1 -1
  647. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/CSSSelector.d.ts.map +1 -1
  648. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/PQuerySelector.d.ts.map +1 -1
  649. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/TextQuerySelector.d.ts.map +1 -1
  650. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/XPathQuerySelector.d.ts.map +1 -1
  651. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/injected.d.ts +4 -4
  652. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/injected.d.ts.map +1 -1
  653. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/util.js +3 -3
  654. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/util.js.map +1 -1
  655. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  656. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js.map +1 -1
  657. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ChromeLauncher.d.ts.map +1 -1
  658. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ChromeLauncher.js +3 -4
  659. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ChromeLauncher.js.map +1 -1
  660. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PipeTransport.d.ts +0 -1
  661. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PipeTransport.d.ts.map +1 -1
  662. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PipeTransport.js.map +1 -1
  663. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ScreenRecorder.d.ts +0 -1
  664. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ScreenRecorder.d.ts.map +1 -1
  665. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/node.d.ts +1 -1
  666. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/node.d.ts.map +1 -1
  667. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/node.js +0 -1
  668. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/node.js.map +1 -1
  669. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/util/fs.js +2 -3
  670. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/util/fs.js.map +1 -1
  671. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/puppeteer-core.d.ts +6 -6
  672. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/puppeteer-core.d.ts.map +1 -1
  673. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/puppeteer-core.js +15 -4
  674. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/puppeteer-core.js.map +1 -1
  675. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.d.ts +3 -3
  676. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +3 -3
  677. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js.map +1 -1
  678. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Deferred.d.ts.map +1 -1
  679. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Deferred.js +1 -0
  680. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Deferred.js.map +1 -1
  681. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/ErrorLike.d.ts +0 -1
  682. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/ErrorLike.d.ts.map +1 -1
  683. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/ErrorLike.js +4 -5
  684. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/ErrorLike.js.map +1 -1
  685. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Function.d.ts.map +1 -1
  686. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Function.js +2 -2
  687. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Function.js.map +1 -1
  688. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Mutex.d.ts +2 -2
  689. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Mutex.d.ts.map +1 -1
  690. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/decorators.d.ts +1 -1
  691. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/decorators.d.ts.map +1 -1
  692. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/decorators.js +18 -13
  693. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/decorators.js.map +1 -1
  694. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/disposable.d.ts.map +1 -1
  695. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/encoding.js +4 -5
  696. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/encoding.js.map +1 -1
  697. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/util.d.ts +1 -0
  698. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/util.d.ts.map +1 -1
  699. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/util.js +1 -0
  700. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/util.js.map +1 -1
  701. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +374 -578
  702. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +316 -150
  703. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.d.ts +2 -2
  704. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.d.ts.map +1 -1
  705. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.js +1 -6
  706. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.js.map +1 -1
  707. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/BrowserContext.d.ts +1 -1
  708. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/BrowserContext.js +1 -1
  709. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/CDPSession.d.ts +1 -1
  710. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/CDPSession.js +1 -1
  711. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts +4 -4
  712. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js +16 -9
  713. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js.map +1 -1
  714. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.d.ts +2 -2
  715. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.js +13 -6
  716. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.js.map +1 -1
  717. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.d.ts +7 -2
  718. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.d.ts.map +1 -1
  719. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.js.map +1 -1
  720. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPResponse.d.ts +0 -1
  721. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPResponse.d.ts.map +1 -1
  722. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Input.d.ts +3 -3
  723. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Input.js +1 -1
  724. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/JSHandle.js +12 -5
  725. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/JSHandle.js.map +1 -1
  726. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts +22 -22
  727. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts.map +1 -1
  728. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js +24 -17
  729. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js.map +1 -1
  730. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/WebWorker.d.ts +2 -2
  731. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/WebWorker.js +2 -2
  732. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/api.d.ts +1 -1
  733. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/api.d.ts.map +1 -1
  734. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/api.js +0 -1
  735. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/api.js.map +1 -1
  736. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/locators/locators.d.ts.map +1 -1
  737. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/locators/locators.js +12 -5
  738. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/locators/locators.js.map +1 -1
  739. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.d.ts +0 -1
  740. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.d.ts.map +1 -1
  741. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.js +4 -0
  742. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.js.map +1 -1
  743. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/BrowserContext.js +12 -5
  744. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/BrowserContext.js.map +1 -1
  745. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ElementHandle.js +12 -5
  746. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ElementHandle.js.map +1 -1
  747. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ExposedFunction.js +12 -5
  748. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ExposedFunction.js.map +1 -1
  749. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.d.ts.map +1 -1
  750. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.js +3 -0
  751. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.js.map +1 -1
  752. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js +21 -10
  753. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js.map +1 -1
  754. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Realm.js +12 -5
  755. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Realm.js.map +1 -1
  756. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js +12 -5
  757. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js.map +1 -1
  758. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/core.d.ts +1 -1
  759. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/core.d.ts.map +1 -1
  760. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/core.js +0 -1
  761. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/core.js.map +1 -1
  762. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/AriaQueryHandler.d.ts.map +1 -1
  763. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/AriaQueryHandler.js +3 -0
  764. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/AriaQueryHandler.js.map +1 -1
  765. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Binding.js +12 -5
  766. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Binding.js.map +1 -1
  767. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Browser.d.ts +0 -1
  768. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Browser.d.ts.map +1 -1
  769. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/BrowserContext.js +12 -5
  770. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/BrowserContext.js.map +1 -1
  771. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ChromeTargetManager.d.ts.map +1 -1
  772. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ChromeTargetManager.js +3 -1
  773. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ChromeTargetManager.js.map +1 -1
  774. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/DeviceRequestPrompt.d.ts +1 -1
  775. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/DeviceRequestPrompt.js +1 -1
  776. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExecutionContext.d.ts +3 -3
  777. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExecutionContext.d.ts.map +1 -1
  778. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExecutionContext.js +17 -13
  779. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExecutionContext.js.map +1 -1
  780. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExtensionTransport.d.ts.map +1 -1
  781. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExtensionTransport.js +5 -1
  782. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExtensionTransport.js.map +1 -1
  783. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/FrameManager.js +1 -1
  784. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/FrameManager.js.map +1 -1
  785. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPResponse.js +1 -1
  786. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPResponse.js.map +1 -1
  787. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Input.d.ts.map +1 -1
  788. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Input.js.map +1 -1
  789. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/IsolatedWorld.d.ts +1 -2
  790. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/IsolatedWorld.d.ts.map +1 -1
  791. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/IsolatedWorld.js.map +1 -1
  792. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.d.ts.map +1 -1
  793. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.js +2 -1
  794. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.js.map +1 -1
  795. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.d.ts +1 -1
  796. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.d.ts.map +1 -1
  797. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.js +16 -7
  798. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.js.map +1 -1
  799. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.d.ts +4 -4
  800. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.d.ts.map +1 -1
  801. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.js +4 -4
  802. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/cdp.d.ts +2 -0
  803. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/cdp.d.ts.map +1 -1
  804. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/cdp.js +2 -0
  805. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/cdp.js.map +1 -1
  806. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/CSSQueryHandler.d.ts.map +1 -1
  807. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/CallbackRegistry.d.ts.map +1 -1
  808. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/CallbackRegistry.js.map +1 -1
  809. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/ConnectOptions.d.ts +3 -0
  810. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/ConnectOptions.d.ts.map +1 -1
  811. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Debug.d.ts.map +1 -1
  812. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Debug.js +0 -1
  813. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Debug.js.map +1 -1
  814. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HandleIterator.js +12 -5
  815. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HandleIterator.js.map +1 -1
  816. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LazyArg.d.ts +1 -1
  817. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LazyArg.d.ts.map +1 -1
  818. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/PierceQueryHandler.d.ts.map +1 -1
  819. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.js +12 -5
  820. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.js.map +1 -1
  821. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/common.d.ts +7 -7
  822. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/common.d.ts.map +1 -1
  823. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/common.js +0 -7
  824. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/common.js.map +1 -1
  825. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.d.ts +2 -3
  826. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.d.ts.map +1 -1
  827. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.js +3 -1
  828. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.js.map +1 -1
  829. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/environment.d.ts +0 -2
  830. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/environment.d.ts.map +1 -1
  831. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.d.ts +1 -1
  832. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.js +1 -1
  833. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/ARIAQuerySelector.d.ts.map +1 -1
  834. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/CSSSelector.d.ts.map +1 -1
  835. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/PQuerySelector.d.ts.map +1 -1
  836. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/TextQuerySelector.d.ts.map +1 -1
  837. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/XPathQuerySelector.d.ts.map +1 -1
  838. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/injected.d.ts +3 -3
  839. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/injected.d.ts.map +1 -1
  840. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  841. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js.map +1 -1
  842. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ChromeLauncher.d.ts.map +1 -1
  843. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ChromeLauncher.js +0 -1
  844. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ChromeLauncher.js.map +1 -1
  845. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.d.ts +0 -1
  846. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.d.ts.map +1 -1
  847. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.js.map +1 -1
  848. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ScreenRecorder.d.ts +0 -1
  849. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ScreenRecorder.d.ts.map +1 -1
  850. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/node.d.ts +1 -1
  851. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/node.d.ts.map +1 -1
  852. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/node.js +0 -1
  853. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/node.js.map +1 -1
  854. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/puppeteer-core-browser.d.ts +1 -1
  855. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/puppeteer-core-browser.d.ts.map +1 -1
  856. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/puppeteer-core.d.ts +6 -6
  857. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/puppeteer-core.d.ts.map +1 -1
  858. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/puppeteer-core.js +3 -4
  859. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/puppeteer-core.js.map +1 -1
  860. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.d.ts +3 -3
  861. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +3 -3
  862. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js.map +1 -1
  863. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/Deferred.d.ts.map +1 -1
  864. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/Deferred.js +1 -0
  865. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/Deferred.js.map +1 -1
  866. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/ErrorLike.d.ts +0 -1
  867. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/ErrorLike.d.ts.map +1 -1
  868. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/Function.d.ts.map +1 -1
  869. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/Mutex.d.ts +1 -1
  870. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/Mutex.d.ts.map +1 -1
  871. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/decorators.d.ts +1 -1
  872. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/decorators.d.ts.map +1 -1
  873. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/decorators.js +12 -6
  874. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/decorators.js.map +1 -1
  875. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/disposable.d.ts.map +1 -1
  876. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/util.d.ts +1 -0
  877. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/util.d.ts.map +1 -1
  878. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/util.js +1 -0
  879. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/util.js.map +1 -1
  880. package/front_end/third_party/puppeteer/package/lib/types.d.ts +374 -578
  881. package/front_end/third_party/puppeteer/package/package.json +6 -6
  882. package/front_end/third_party/puppeteer/package/src/api/Browser.ts +8 -8
  883. package/front_end/third_party/puppeteer/package/src/api/BrowserContext.ts +5 -5
  884. package/front_end/third_party/puppeteer/package/src/api/CDPSession.ts +2 -2
  885. package/front_end/third_party/puppeteer/package/src/api/Dialog.ts +1 -1
  886. package/front_end/third_party/puppeteer/package/src/api/ElementHandle.ts +44 -44
  887. package/front_end/third_party/puppeteer/package/src/api/Frame.ts +33 -33
  888. package/front_end/third_party/puppeteer/package/src/api/HTTPRequest.ts +14 -9
  889. package/front_end/third_party/puppeteer/package/src/api/Input.ts +11 -11
  890. package/front_end/third_party/puppeteer/package/src/api/JSHandle.ts +5 -5
  891. package/front_end/third_party/puppeteer/package/src/api/Page.ts +88 -87
  892. package/front_end/third_party/puppeteer/package/src/api/Realm.ts +2 -2
  893. package/front_end/third_party/puppeteer/package/src/api/WebWorker.ts +2 -2
  894. package/front_end/third_party/puppeteer/package/src/api/api.ts +1 -1
  895. package/front_end/third_party/puppeteer/package/src/api/locators/locators.ts +79 -79
  896. package/front_end/third_party/puppeteer/package/src/bidi/BidiOverCdp.ts +7 -7
  897. package/front_end/third_party/puppeteer/package/src/bidi/Browser.ts +9 -5
  898. package/front_end/third_party/puppeteer/package/src/bidi/BrowserConnector.ts +5 -5
  899. package/front_end/third_party/puppeteer/package/src/bidi/BrowserContext.ts +10 -10
  900. package/front_end/third_party/puppeteer/package/src/bidi/CDPSession.ts +4 -4
  901. package/front_end/third_party/puppeteer/package/src/bidi/Connection.ts +6 -6
  902. package/front_end/third_party/puppeteer/package/src/bidi/ElementHandle.ts +3 -3
  903. package/front_end/third_party/puppeteer/package/src/bidi/ExposedFunction.ts +11 -11
  904. package/front_end/third_party/puppeteer/package/src/bidi/Frame.ts +45 -41
  905. package/front_end/third_party/puppeteer/package/src/bidi/HTTPRequest.ts +9 -9
  906. package/front_end/third_party/puppeteer/package/src/bidi/HTTPResponse.ts +3 -3
  907. package/front_end/third_party/puppeteer/package/src/bidi/Input.ts +10 -10
  908. package/front_end/third_party/puppeteer/package/src/bidi/JSHandle.ts +1 -1
  909. package/front_end/third_party/puppeteer/package/src/bidi/Page.ts +56 -52
  910. package/front_end/third_party/puppeteer/package/src/bidi/Realm.ts +15 -15
  911. package/front_end/third_party/puppeteer/package/src/bidi/Serializer.ts +1 -1
  912. package/front_end/third_party/puppeteer/package/src/bidi/Target.ts +2 -2
  913. package/front_end/third_party/puppeteer/package/src/bidi/WebWorker.ts +2 -2
  914. package/front_end/third_party/puppeteer/package/src/bidi/core/Browser.ts +4 -4
  915. package/front_end/third_party/puppeteer/package/src/bidi/core/BrowsingContext.ts +17 -17
  916. package/front_end/third_party/puppeteer/package/src/bidi/core/Connection.ts +1 -1
  917. package/front_end/third_party/puppeteer/package/src/bidi/core/Navigation.ts +3 -3
  918. package/front_end/third_party/puppeteer/package/src/bidi/core/Realm.ts +6 -6
  919. package/front_end/third_party/puppeteer/package/src/bidi/core/Request.ts +5 -5
  920. package/front_end/third_party/puppeteer/package/src/bidi/core/Session.ts +4 -4
  921. package/front_end/third_party/puppeteer/package/src/bidi/core/UserContext.ts +9 -9
  922. package/front_end/third_party/puppeteer/package/src/bidi/core/UserPrompt.ts +4 -4
  923. package/front_end/third_party/puppeteer/package/src/bidi/core/core.ts +1 -1
  924. package/front_end/third_party/puppeteer/package/src/bidi/util.ts +4 -4
  925. package/front_end/third_party/puppeteer/package/src/cdp/Accessibility.ts +7 -7
  926. package/front_end/third_party/puppeteer/package/src/cdp/AriaQueryHandler.ts +10 -6
  927. package/front_end/third_party/puppeteer/package/src/cdp/Binding.ts +6 -6
  928. package/front_end/third_party/puppeteer/package/src/cdp/Browser.ts +24 -24
  929. package/front_end/third_party/puppeteer/package/src/cdp/BrowserConnector.ts +4 -4
  930. package/front_end/third_party/puppeteer/package/src/cdp/BrowserContext.ts +2 -2
  931. package/front_end/third_party/puppeteer/package/src/cdp/CDPSession.ts +7 -7
  932. package/front_end/third_party/puppeteer/package/src/cdp/ChromeTargetManager.ts +19 -17
  933. package/front_end/third_party/puppeteer/package/src/cdp/Connection.ts +7 -7
  934. package/front_end/third_party/puppeteer/package/src/cdp/Coverage.ts +11 -11
  935. package/front_end/third_party/puppeteer/package/src/cdp/DeviceRequestPrompt.ts +17 -17
  936. package/front_end/third_party/puppeteer/package/src/cdp/Dialog.ts +1 -1
  937. package/front_end/third_party/puppeteer/package/src/cdp/ElementHandle.ts +6 -6
  938. package/front_end/third_party/puppeteer/package/src/cdp/EmulationManager.ts +34 -34
  939. package/front_end/third_party/puppeteer/package/src/cdp/ExecutionContext.ts +18 -19
  940. package/front_end/third_party/puppeteer/package/src/cdp/ExtensionTransport.ts +7 -3
  941. package/front_end/third_party/puppeteer/package/src/cdp/FirefoxTargetManager.ts +7 -7
  942. package/front_end/third_party/puppeteer/package/src/cdp/Frame.ts +16 -16
  943. package/front_end/third_party/puppeteer/package/src/cdp/FrameManager.ts +20 -20
  944. package/front_end/third_party/puppeteer/package/src/cdp/FrameManagerEvents.ts +1 -1
  945. package/front_end/third_party/puppeteer/package/src/cdp/HTTPRequest.ts +5 -5
  946. package/front_end/third_party/puppeteer/package/src/cdp/HTTPResponse.ts +5 -5
  947. package/front_end/third_party/puppeteer/package/src/cdp/Input.ts +16 -14
  948. package/front_end/third_party/puppeteer/package/src/cdp/IsolatedWorld.ts +14 -13
  949. package/front_end/third_party/puppeteer/package/src/cdp/JSHandle.ts +2 -2
  950. package/front_end/third_party/puppeteer/package/src/cdp/LifecycleWatcher.ts +11 -11
  951. package/front_end/third_party/puppeteer/package/src/cdp/NetworkEventManager.ts +15 -15
  952. package/front_end/third_party/puppeteer/package/src/cdp/NetworkManager.ts +38 -37
  953. package/front_end/third_party/puppeteer/package/src/cdp/Page.ts +71 -70
  954. package/front_end/third_party/puppeteer/package/src/cdp/PredefinedNetworkConditions.ts +4 -4
  955. package/front_end/third_party/puppeteer/package/src/cdp/Target.ts +4 -4
  956. package/front_end/third_party/puppeteer/package/src/cdp/TargetManager.ts +1 -1
  957. package/front_end/third_party/puppeteer/package/src/cdp/Tracing.ts +2 -2
  958. package/front_end/third_party/puppeteer/package/src/cdp/WebWorker.ts +5 -5
  959. package/front_end/third_party/puppeteer/package/src/cdp/cdp.ts +2 -0
  960. package/front_end/third_party/puppeteer/package/src/cdp/utils.ts +10 -10
  961. package/front_end/third_party/puppeteer/package/src/common/BrowserConnector.ts +5 -5
  962. package/front_end/third_party/puppeteer/package/src/common/CSSQueryHandler.ts +2 -2
  963. package/front_end/third_party/puppeteer/package/src/common/CallbackRegistry.ts +9 -7
  964. package/front_end/third_party/puppeteer/package/src/common/ConnectOptions.ts +3 -0
  965. package/front_end/third_party/puppeteer/package/src/common/ConsoleMessage.ts +1 -1
  966. package/front_end/third_party/puppeteer/package/src/common/CustomQueryHandler.ts +6 -6
  967. package/front_end/third_party/puppeteer/package/src/common/Debug.ts +0 -1
  968. package/front_end/third_party/puppeteer/package/src/common/EventEmitter.ts +8 -8
  969. package/front_end/third_party/puppeteer/package/src/common/FileChooser.ts +3 -3
  970. package/front_end/third_party/puppeteer/package/src/common/HandleIterator.ts +3 -3
  971. package/front_end/third_party/puppeteer/package/src/common/LazyArg.ts +1 -1
  972. package/front_end/third_party/puppeteer/package/src/common/NetworkManagerEvents.ts +1 -1
  973. package/front_end/third_party/puppeteer/package/src/common/PQueryHandler.ts +2 -2
  974. package/front_end/third_party/puppeteer/package/src/common/PSelectorParser.ts +1 -1
  975. package/front_end/third_party/puppeteer/package/src/common/PierceQueryHandler.ts +2 -2
  976. package/front_end/third_party/puppeteer/package/src/common/Puppeteer.ts +1 -1
  977. package/front_end/third_party/puppeteer/package/src/common/QueryHandler.ts +12 -12
  978. package/front_end/third_party/puppeteer/package/src/common/TaskQueue.ts +1 -1
  979. package/front_end/third_party/puppeteer/package/src/common/TextQueryHandler.ts +1 -1
  980. package/front_end/third_party/puppeteer/package/src/common/WaitTask.ts +8 -8
  981. package/front_end/third_party/puppeteer/package/src/common/XPathQueryHandler.ts +2 -2
  982. package/front_end/third_party/puppeteer/package/src/common/common.ts +7 -7
  983. package/front_end/third_party/puppeteer/package/src/common/util.ts +15 -14
  984. package/front_end/third_party/puppeteer/package/src/generated/version.ts +1 -1
  985. package/front_end/third_party/puppeteer/package/src/injected/ARIAQuerySelector.ts +3 -3
  986. package/front_end/third_party/puppeteer/package/src/injected/CSSSelector.ts +2 -2
  987. package/front_end/third_party/puppeteer/package/src/injected/PQuerySelector.ts +7 -7
  988. package/front_end/third_party/puppeteer/package/src/injected/PierceQuerySelector.ts +2 -2
  989. package/front_end/third_party/puppeteer/package/src/injected/TextContent.ts +1 -1
  990. package/front_end/third_party/puppeteer/package/src/injected/TextQuerySelector.ts +1 -1
  991. package/front_end/third_party/puppeteer/package/src/injected/XPathQuerySelector.ts +2 -2
  992. package/front_end/third_party/puppeteer/package/src/injected/util.ts +2 -2
  993. package/front_end/third_party/puppeteer/package/src/node/BrowserLauncher.ts +38 -30
  994. package/front_end/third_party/puppeteer/package/src/node/ChromeLauncher.ts +11 -12
  995. package/front_end/third_party/puppeteer/package/src/node/FirefoxLauncher.ts +8 -8
  996. package/front_end/third_party/puppeteer/package/src/node/NodeWebSocketTransport.ts +1 -1
  997. package/front_end/third_party/puppeteer/package/src/node/PipeTransport.ts +7 -3
  998. package/front_end/third_party/puppeteer/package/src/node/PuppeteerNode.ts +4 -4
  999. package/front_end/third_party/puppeteer/package/src/node/ScreenRecorder.ts +10 -10
  1000. package/front_end/third_party/puppeteer/package/src/node/node.ts +1 -1
  1001. package/front_end/third_party/puppeteer/package/src/puppeteer-core.ts +4 -4
  1002. package/front_end/third_party/puppeteer/package/src/revisions.ts +3 -3
  1003. package/front_end/third_party/puppeteer/package/src/util/AsyncIterableUtil.ts +3 -3
  1004. package/front_end/third_party/puppeteer/package/src/util/Deferred.ts +3 -2
  1005. package/front_end/third_party/puppeteer/package/src/util/ErrorLike.ts +1 -1
  1006. package/front_end/third_party/puppeteer/package/src/util/Function.ts +4 -4
  1007. package/front_end/third_party/puppeteer/package/src/util/Mutex.ts +1 -1
  1008. package/front_end/third_party/puppeteer/package/src/util/assert.ts +1 -1
  1009. package/front_end/third_party/puppeteer/package/src/util/decorators.ts +8 -9
  1010. package/front_end/third_party/puppeteer/package/src/util/encoding.ts +1 -1
  1011. package/front_end/third_party/puppeteer/package/src/util/util.ts +1 -0
  1012. package/front_end/third_party/web-vitals/README.chromium +3 -3
  1013. package/front_end/third_party/web-vitals/package/README.md +36 -23
  1014. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.d.ts +2 -1
  1015. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.js +11 -13
  1016. package/front_end/third_party/web-vitals/package/dist/modules/lib/bindReporter.d.ts +2 -22
  1017. package/front_end/third_party/web-vitals/package/dist/modules/lib/initMetric.d.ts +3 -2
  1018. package/front_end/third_party/web-vitals/package/dist/modules/lib/interactions.js +1 -1
  1019. package/front_end/third_party/web-vitals/package/dist/modules/onLCP.js +4 -1
  1020. package/front_end/third_party/web-vitals/package/dist/web-vitals.attribution.iife.js +1 -1
  1021. package/front_end/third_party/web-vitals/package/dist/web-vitals.attribution.js +1 -1
  1022. package/front_end/third_party/web-vitals/package/dist/web-vitals.attribution.umd.cjs +1 -1
  1023. package/front_end/third_party/web-vitals/package/dist/web-vitals.iife.js +1 -1
  1024. package/front_end/third_party/web-vitals/package/dist/web-vitals.js +1 -1
  1025. package/front_end/third_party/web-vitals/package/dist/web-vitals.umd.cjs +1 -1
  1026. package/front_end/third_party/web-vitals/package/package.json +1 -1
  1027. package/front_end/third_party/web-vitals/package/src/attribution/onINP.ts +11 -14
  1028. package/front_end/third_party/web-vitals/package/src/lib/interactions.ts +1 -1
  1029. package/front_end/third_party/web-vitals/package/src/onLCP.ts +4 -1
  1030. package/front_end/third_party/web-vitals/rebuild.sh +14 -0
  1031. package/front_end/third_party/web-vitals/web-vitals.ts +2 -0
  1032. package/front_end/ui/components/adorners/Adorner.ts +0 -1
  1033. package/front_end/ui/components/buttons/Button.ts +0 -1
  1034. package/front_end/ui/components/buttons/button.css +1 -0
  1035. package/front_end/ui/components/cards/Card.test.ts +31 -5
  1036. package/front_end/ui/components/cards/Card.ts +22 -3
  1037. package/front_end/ui/components/cards/card.css +25 -7
  1038. package/front_end/ui/components/chrome_link/ChromeLink.ts +0 -1
  1039. package/front_end/ui/components/data_grid/DataGrid.ts +0 -1
  1040. package/front_end/ui/components/data_grid/DataGridController.ts +2 -3
  1041. package/front_end/ui/components/data_grid/DataGridControllerIntegrator.ts +1 -2
  1042. package/front_end/ui/components/dialogs/Dialog.ts +0 -1
  1043. package/front_end/ui/components/dialogs/IconDialog.ts +9 -11
  1044. package/front_end/ui/components/dialogs/ShortcutDialog.ts +3 -4
  1045. package/front_end/ui/components/diff_view/DiffView.ts +0 -1
  1046. package/front_end/ui/components/docs/building-ui-documentation/ComponentPerformance.md +1 -4
  1047. package/front_end/ui/components/docs/building-ui-documentation/CreatingComponents.md +14 -44
  1048. package/front_end/ui/components/docs/freestyler/basic.ts +2 -3
  1049. package/front_end/ui/components/docs/freestyler/empty_state.ts +2 -2
  1050. package/front_end/ui/components/docs/icon_dialog/basic.ts +4 -4
  1051. package/front_end/ui/components/docs/performance_panel/basic.ts +4 -1
  1052. package/front_end/ui/components/docs/report/basic.ts +3 -3
  1053. package/front_end/ui/components/expandable_list/ExpandableList.ts +0 -1
  1054. package/front_end/ui/components/floating_button/FloatingButton.ts +0 -1
  1055. package/front_end/ui/components/icon_button/FileSourceIcon.test.ts +32 -0
  1056. package/front_end/ui/components/icon_button/FileSourceIcon.ts +76 -0
  1057. package/front_end/ui/components/icon_button/Icon.ts +0 -3
  1058. package/front_end/ui/components/icon_button/IconButton.ts +0 -1
  1059. package/front_end/ui/components/icon_button/fileSourceIcon.css +43 -0
  1060. package/front_end/ui/components/icon_button/icon_button.ts +2 -0
  1061. package/front_end/ui/components/issue_counter/IssueCounter.ts +1 -3
  1062. package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +0 -1
  1063. package/front_end/ui/components/legacy_wrapper/LegacyWrapper.ts +1 -1
  1064. package/front_end/ui/components/linkifier/LinkifierImpl.ts +4 -2
  1065. package/front_end/ui/components/markdown_view/CodeBlock.ts +0 -1
  1066. package/front_end/ui/components/markdown_view/MarkdownImage.ts +0 -1
  1067. package/front_end/ui/components/markdown_view/MarkdownLink.ts +0 -1
  1068. package/front_end/ui/components/markdown_view/MarkdownView.ts +10 -7
  1069. package/front_end/ui/components/menus/Menu.ts +0 -3
  1070. package/front_end/ui/components/menus/SelectMenu.ts +0 -2
  1071. package/front_end/ui/components/menus/selectMenu.css +8 -5
  1072. package/front_end/ui/components/menus/selectMenuButton.css +29 -17
  1073. package/front_end/ui/components/node_text/NodeText.ts +0 -1
  1074. package/front_end/ui/components/panel_feedback/FeedbackButton.ts +0 -1
  1075. package/front_end/ui/components/panel_feedback/PanelFeedback.ts +1 -3
  1076. package/front_end/ui/components/panel_feedback/PreviewToggle.ts +1 -3
  1077. package/front_end/ui/components/panel_introduction_steps/PanelIntroductionSteps.ts +0 -1
  1078. package/front_end/ui/components/report_view/ReportView.ts +1 -7
  1079. package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +0 -1
  1080. package/front_end/ui/components/settings/SettingCheckbox.ts +28 -10
  1081. package/front_end/ui/components/settings/SettingDeprecationWarning.ts +2 -4
  1082. package/front_end/ui/components/settings/settingCheckbox.css +1 -0
  1083. package/front_end/ui/components/spinners/Spinner.ts +0 -1
  1084. package/front_end/ui/components/spinners/spinner.css +1 -0
  1085. package/front_end/ui/components/split_view/SplitView.ts +0 -1
  1086. package/front_end/ui/components/srgb_overlay/SrgbOverlay.ts +0 -1
  1087. package/front_end/ui/components/survey_link/SurveyLink.ts +1 -3
  1088. package/front_end/ui/components/switch/SwitchImpl.ts +0 -1
  1089. package/front_end/ui/components/text_editor/TextEditor.ts +0 -2
  1090. package/front_end/ui/components/text_prompt/TextPrompt.ts +0 -1
  1091. package/front_end/ui/components/tree_outline/TreeOutline.ts +0 -1
  1092. package/front_end/ui/components/two_states_counter/TwoStatesCounter.ts +0 -1
  1093. package/front_end/ui/legacy/ContextMenu.ts +46 -7
  1094. package/front_end/ui/legacy/FilterBar.test.ts +52 -0
  1095. package/front_end/ui/legacy/FilterBar.ts +46 -1
  1096. package/front_end/ui/legacy/KeyboardShortcut.ts +35 -21
  1097. package/front_end/ui/legacy/Panel.ts +2 -2
  1098. package/front_end/ui/legacy/ShortcutRegistry.ts +10 -7
  1099. package/front_end/ui/legacy/SoftContextMenu.ts +3 -0
  1100. package/front_end/ui/legacy/ThrottledWidget.ts +2 -2
  1101. package/front_end/ui/legacy/Toolbar.ts +1 -0
  1102. package/front_end/ui/legacy/Treeoutline.ts +7 -4
  1103. package/front_end/ui/legacy/UIUtils.ts +9 -0
  1104. package/front_end/ui/legacy/View.ts +2 -2
  1105. package/front_end/ui/legacy/ViewManager.ts +2 -1
  1106. package/front_end/ui/legacy/Widget.ts +4 -4
  1107. package/front_end/ui/legacy/components/data_grid/DataGrid.test.ts +51 -0
  1108. package/front_end/ui/legacy/components/data_grid/DataGrid.ts +92 -6
  1109. package/front_end/ui/legacy/components/data_grid/dataGrid.css +8 -1
  1110. package/front_end/ui/legacy/components/inline_editor/CSSAngle.ts +4 -7
  1111. package/front_end/ui/legacy/components/inline_editor/CSSAngleEditor.ts +0 -1
  1112. package/front_end/ui/legacy/components/inline_editor/CSSAngleSwatch.ts +0 -1
  1113. package/front_end/ui/legacy/components/inline_editor/CSSLength.ts +0 -1
  1114. package/front_end/ui/legacy/components/inline_editor/ColorMixSwatch.ts +0 -1
  1115. package/front_end/ui/legacy/components/inline_editor/ColorSwatch.ts +0 -1
  1116. package/front_end/ui/legacy/components/inline_editor/LinkSwatch.ts +0 -3
  1117. package/front_end/ui/legacy/components/inline_editor/Swatches.ts +1 -2
  1118. package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +2 -2
  1119. package/front_end/ui/legacy/components/perf_ui/CanvasHelper.ts +1 -83
  1120. package/front_end/ui/legacy/components/perf_ui/ChartViewport.ts +3 -2
  1121. package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +162 -57
  1122. package/front_end/ui/legacy/components/perf_ui/PieChart.ts +0 -1
  1123. package/front_end/ui/legacy/components/perf_ui/TimelineOverviewPane.ts +3 -3
  1124. package/front_end/ui/legacy/components/source_frame/BinaryResourceViewFactory.test.ts +5 -9
  1125. package/front_end/ui/legacy/components/source_frame/BinaryResourceViewFactory.ts +9 -60
  1126. package/front_end/ui/legacy/components/source_frame/SourceFrame.test.ts +18 -0
  1127. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +20 -3
  1128. package/front_end/{panels/network/RequestBinaryResponseView.test.ts → ui/legacy/components/source_frame/StreamingContentHexView.test.ts} +12 -12
  1129. package/front_end/ui/legacy/components/source_frame/StreamingContentHexView.ts +122 -0
  1130. package/front_end/ui/legacy/components/source_frame/source_frame.ts +2 -0
  1131. package/front_end/ui/legacy/designTokens.css +46 -40
  1132. package/front_end/ui/legacy/filter.css +23 -8
  1133. package/front_end/ui/legacy/inspectorCommon.css +31 -29
  1134. package/front_end/ui/legacy/searchableView.css +4 -3
  1135. package/front_end/ui/legacy/softDropDownButton.css +10 -6
  1136. package/front_end/ui/legacy/tabbedPane.css +1 -1
  1137. package/front_end/ui/legacy/toolbar.css +38 -18
  1138. package/front_end/ui/visual_logging/KnownContextValues.ts +67 -1
  1139. package/front_end/ui/visual_logging/LoggingDriver.test.ts +53 -6
  1140. package/front_end/ui/visual_logging/LoggingDriver.ts +8 -5
  1141. package/front_end/ui/visual_logging/LoggingEvents.test.ts +5 -1
  1142. package/front_end/ui/visual_logging/LoggingEvents.ts +1 -1
  1143. package/front_end/ui/visual_logging/LoggingState.ts +1 -1
  1144. package/package.json +5 -6
  1145. package/scripts/build/esbuild.js +3 -1
  1146. package/scripts/devtools_paths.js +11 -1
  1147. package/scripts/eslint_rules/lib/check_test_definitions.js +1 -1
  1148. package/scripts/eslint_rules/tests/check_test_definitions_test.js +10 -0
  1149. package/tsconfig.json +11 -1
  1150. package/docs/add_uma_metrics.md +0 -41
  1151. package/docs/uma_metrics.md +0 -23
  1152. package/front_end/panels/animation/AnimationDOMNode.ts +0 -268
  1153. package/front_end/panels/freestyler/components/ProvideFeedback.test.ts +0 -29
  1154. package/front_end/panels/freestyler/components/provideFeedback.css +0 -60
  1155. package/front_end/panels/network/RequestBinaryResponseView.ts +0 -67
  1156. package/scripts/eslint_rules/lib/lit_html_data_as_type.js +0 -83
  1157. package/scripts/eslint_rules/tests/lit_html_data_as_type_test.js +0 -81
@@ -42,7 +42,10 @@ The library supports all of the [Core Web Vitals](https://web.dev/articles/vital
42
42
 
43
43
  - [First Contentful Paint (FCP)](https://web.dev/articles/fcp)
44
44
  - [Time to First Byte (TTFB)](https://web.dev/articles/ttfb)
45
- - [First Input Delay (FID)](https://web.dev/articles/fid) _Deprecated and will be removed in next major release_
45
+ - [First Input Delay (FID)](https://web.dev/articles/fid)
46
+
47
+ > [!CAUTION]
48
+ > FID is deprecated and will be removed in the next major release.
46
49
 
47
50
  <a name="installation"><a>
48
51
  <a name="load-the-library"><a>
@@ -63,7 +66,8 @@ You can install this library from npm by running:
63
66
  npm install web-vitals
64
67
  ```
65
68
 
66
- _**Note:** If you're not using npm, you can still load `web-vitals` via `<script>` tags from a CDN like [unpkg.com](https://unpkg.com). See the [load `web-vitals` from a CDN](#load-web-vitals-from-a-cdn) usage example below for details._
69
+ > [!NOTE]
70
+ > If you're not using npm, you can still load `web-vitals` via `<script>` tags from a CDN like [unpkg.com](https://unpkg.com). See the [load `web-vitals` from a CDN](#load-web-vitals-from-a-cdn) usage example below for details.
67
71
 
68
72
  There are a few different builds of the `web-vitals` library, and how you load the library depends on which build you want to use.
69
73
 
@@ -81,7 +85,8 @@ onINP(console.log);
81
85
  onLCP(console.log);
82
86
  ```
83
87
 
84
- _**Note:** in version 2, these functions were named `getXXX()` rather than `onXXX()`. They've [been renamed](https://github.com/GoogleChrome/web-vitals/pull/222) in version 3 to reduce confusion (see [#217](https://github.com/GoogleChrome/web-vitals/pull/217) for details) and will continue to be available using the `getXXX()` until at least version 4. Users are encouraged to switch to the new names, though, for future compatibility._
88
+ > [!NOTE]
89
+ > In version 2, these functions were named `getXXX()` rather than `onXXX()`. They've [been renamed](https://github.com/GoogleChrome/web-vitals/pull/222) in version 3 to reduce confusion (see [#217](https://github.com/GoogleChrome/web-vitals/pull/217) for details) and will continue to be available using the `getXXX()` until at least version 4. Users are encouraged to switch to the new names, though, for future compatibility.
85
90
 
86
91
  <a name="attribution-build"><a>
87
92
 
@@ -213,13 +218,15 @@ In other cases, a metric callback may be called more than once:
213
218
  - CLS and INP should be reported any time the [page's `visibilityState` changes to hidden](https://developer.chrome.com/blog/page-lifecycle-api/#advice-hidden).
214
219
  - All metrics are reported again (with the above exceptions) after a page is restored from the [back/forward cache](https://web.dev/articles/bfcache).
215
220
 
216
- _**Warning:** do not call any of the Web Vitals functions (e.g. `onCLS()`, `onINP()`, `onLCP()`) more than once per page load. Each of these functions creates a `PerformanceObserver` instance and registers event listeners for the lifetime of the page. While the overhead of calling these functions once is negligible, calling them repeatedly on the same page may eventually result in a memory leak._
221
+ > [!WARNING]
222
+ > Do not call any of the Web Vitals functions (e.g. `onCLS()`, `onINP()`, `onLCP()`) more than once per page load. Each of these functions creates a `PerformanceObserver` instance and registers event listeners for the lifetime of the page. While the overhead of calling these functions once is negligible, calling them repeatedly on the same page may eventually result in a memory leak.
217
223
 
218
224
  ### Report the value on every change
219
225
 
220
226
  In most cases, you only want the `callback` function to be called when the metric is ready to be reported. However, it is possible to report every change (e.g. each larger layout shift as it happens) by setting `reportAllChanges` to `true` in the optional, [configuration object](#reportopts) (second parameter).
221
227
 
222
- _**Important:** `reportAllChanges` only reports when the **metric changes**, not for each **input to the metric**. For example, a new layout shift that does not increase the CLS metric will not be reported even with `reportAllChanges` set to `true` because the CLS metric has not changed. Similarly, for INP, each interaction is not reported even with `reportAllChanges` set to `true`—just when an interaction causes an increase to INP._
228
+ > [!IMPORTANT]
229
+ > `reportAllChanges` only reports when the **metric changes**, not for each **input to the metric**. For example, a new layout shift that does not increase the CLS metric will not be reported even with `reportAllChanges` set to `true` because the CLS metric has not changed. Similarly, for INP, each interaction is not reported even with `reportAllChanges` set to `true`—just when an interaction causes an increase to INP.
223
230
 
224
231
  This can be useful when debugging, but in general using `reportAllChanges` is not needed (or recommended) for measuring these metrics in production.
225
232
 
@@ -250,7 +257,8 @@ onINP(logDelta);
250
257
  onLCP(logDelta);
251
258
  ```
252
259
 
253
- _**Note:** the first time the `callback` function is called, its `value` and `delta` properties will be the same._
260
+ > [!NOTE]
261
+ > The first time the `callback` function is called, its `value` and `delta` properties will be the same.
254
262
 
255
263
  In addition to using the `id` field to group multiple deltas for the same metric, it can also be used to differentiate different metrics reported on the same page. For example, after a back/forward cache restore, a new metric object is created with a new `id` (since back/forward cache restores are considered separate page visits).
256
264
 
@@ -361,7 +369,8 @@ onINP(sendToGoogleAnalytics);
361
369
  onLCP(sendToGoogleAnalytics);
362
370
  ```
363
371
 
364
- _**Note:** this example relies on custom [event parameters](https://support.google.com/analytics/answer/11396839) in Google Analytics 4._
372
+ > [!NOTE]
373
+ > This example relies on custom [event parameters](https://support.google.com/analytics/answer/11396839) in Google Analytics 4.
365
374
 
366
375
  See [Debug performance in the field](https://web.dev/articles/debug-performance-in-the-field) for more information and examples.
367
376
 
@@ -405,14 +414,10 @@ addEventListener('visibilitychange', () => {
405
414
  flushQueue();
406
415
  }
407
416
  });
408
-
409
- // NOTE: Safari does not reliably fire the `visibilitychange` event when the
410
- // page is being unloaded. If Safari support is needed, you should also flush
411
- // the queue in the `pagehide` event.
412
- addEventListener('pagehide', flushQueue);
413
417
  ```
414
418
 
415
- _**Note:** see [the Page Lifecycle guide](https://developers.google.com/web/updates/2018/07/page-lifecycle-api#legacy-lifecycle-apis-to-avoid) for an explanation of why `visibilitychange` and `pagehide` are recommended over events like `beforeunload` and `unload`._
419
+ > [!NOTE]
420
+ > See [the Page Lifecycle guide](https://developers.google.com/web/updates/2018/07/page-lifecycle-api#legacy-lifecycle-apis-to-avoid) for an explanation of why `visibilitychange` is recommended over events like `beforeunload` and `unload`.
416
421
 
417
422
  <a name="bundle-versions"><a>
418
423
 
@@ -580,7 +585,8 @@ interface FCPMetric extends Metric {
580
585
 
581
586
  ##### `FIDMetric`
582
587
 
583
- _This interface is deprecated and will be removed in next major release_
588
+ > [!CAUTION]
589
+ > This interface is deprecated and will be removed in the next major release.
584
590
 
585
591
  ```ts
586
592
  interface FIDMetric extends Metric {
@@ -684,7 +690,8 @@ Calculates the [CLS](https://web.dev/articles/cls) value for the current page an
684
690
 
685
691
  If the `reportAllChanges` [configuration option](#reportopts) is set to `true`, the `callback` function will be called as soon as the value is initially determined as well as any time the value changes throughout the page lifespan (Note [not necessarily for every layout shift](#report-the-value-on-every-change)).
686
692
 
687
- _**Important:** CLS should be continually monitored for changes throughout the entire lifespan of a page—including if the user returns to the page after it's been hidden/backgrounded. However, since browsers often [will not fire additional callbacks once the user has backgrounded a page](https://developer.chrome.com/blog/page-lifecycle-api/#advice-hidden), `callback` is always called when the page's visibility state changes to hidden. As a result, the `callback` function might be called multiple times during the same page load (see [Reporting only the delta of changes](#report-only-the-delta-of-changes) for how to manage this)._
693
+ > [!IMPORTANT]
694
+ > CLS should be continually monitored for changes throughout the entire lifespan of a page—including if the user returns to the page after it's been hidden/backgrounded. However, since browsers often [will not fire additional callbacks once the user has backgrounded a page](https://developer.chrome.com/blog/page-lifecycle-api/#advice-hidden), `callback` is always called when the page's visibility state changes to hidden. As a result, the `callback` function might be called multiple times during the same page load (see [Reporting only the delta of changes](#report-only-the-delta-of-changes) for how to manage this).
688
695
 
689
696
  #### `onFCP()`
690
697
 
@@ -696,7 +703,8 @@ Calculates the [FCP](https://web.dev/articles/fcp) value for the current page an
696
703
 
697
704
  #### `onFID()`
698
705
 
699
- _This function is deprecated and will be removed in next major release_
706
+ > [!CAUTION]
707
+ > This function is deprecated and will be removed in the next major release.
700
708
 
701
709
  ```ts
702
710
  function onFID(callback: (metric: FIDMetric) => void, opts?: ReportOpts): void;
@@ -704,7 +712,8 @@ function onFID(callback: (metric: FIDMetric) => void, opts?: ReportOpts): void;
704
712
 
705
713
  Calculates the [FID](https://web.dev/articles/fid) value for the current page and calls the `callback` function once the value is ready, along with the relevant `first-input` performance entry used to determine the value. The reported value is a [`DOMHighResTimeStamp`](https://developer.mozilla.org/docs/Web/API/DOMHighResTimeStamp).
706
714
 
707
- _**Important:** since FID is only reported after the user interacts with the page, it's possible that it will not be reported for some page loads._
715
+ > [!IMPORTANT]
716
+ > Since FID is only reported after the user interacts with the page, it's possible that it will not be reported for some page loads.
708
717
 
709
718
  #### `onINP()`
710
719
 
@@ -718,7 +727,8 @@ A custom `durationThreshold` [configuration option](#reportopts) can optionally
718
727
 
719
728
  If the `reportAllChanges` [configuration option](#reportopts) is set to `true`, the `callback` function will be called as soon as the value is initially determined as well as any time the value changes throughout the page lifespan (Note [not necessarily for every interaction](#report-the-value-on-every-change)).
720
729
 
721
- _**Important:** INP should be continually monitored for changes throughout the entire lifespan of a page—including if the user returns to the page after it's been hidden/backgrounded. However, since browsers often [will not fire additional callbacks once the user has backgrounded a page](https://developer.chrome.com/blog/page-lifecycle-api/#advice-hidden), `callback` is always called when the page's visibility state changes to hidden. As a result, the `callback` function might be called multiple times during the same page load (see [Reporting only the delta of changes](#report-only-the-delta-of-changes) for how to manage this)._
730
+ > [!IMPORTANT]
731
+ > INP should be continually monitored for changes throughout the entire lifespan of a page—including if the user returns to the page after it's been hidden/backgrounded. However, since browsers often [will not fire additional callbacks once the user has backgrounded a page](https://developer.chrome.com/blog/page-lifecycle-api/#advice-hidden), `callback` is always called when the page's visibility state changes to hidden. As a result, the `callback` function might be called multiple times during the same page load (see [Reporting only the delta of changes](#report-only-the-delta-of-changes) for how to manage this).
722
732
 
723
733
  #### `onLCP()`
724
734
 
@@ -756,8 +766,8 @@ onTTFB((metric) => {
756
766
  });
757
767
  ```
758
768
 
759
- _**Note:** browsers that do not support `navigation` entries will fall back to
760
- using `performance.timing` (with the timestamps converted from epoch time to [`DOMHighResTimeStamp`](https://developer.mozilla.org/docs/Web/API/DOMHighResTimeStamp)). This ensures code referencing these values (like in the example above) will work the same in all browsers._
769
+ > [!NOTE]
770
+ > Browsers that do not support `navigation` entries will fall back to using `performance.timing` (with the timestamps converted from epoch time to [`DOMHighResTimeStamp`](https://developer.mozilla.org/docs/Web/API/DOMHighResTimeStamp)). This ensures code referencing these values (like in the example above) will work the same in all browsers.
761
771
 
762
772
  ### Rating Thresholds:
763
773
 
@@ -773,7 +783,8 @@ console.log(INPThresholds); // [ 200, 500 ]
773
783
  console.log(LCPThresholds); // [ 2500, 4000 ]
774
784
  ```
775
785
 
776
- _**Note:** It's typically not necessary (or recommended) to manually calculate metric value ratings using these thresholds. Use the [`Metric['rating']`](#metric) instead._
786
+ > [!NOTE]
787
+ > It's typically not necessary (or recommended) to manually calculate metric value ratings using these thresholds. Use the [`Metric['rating']`](#metric) instead.
777
788
 
778
789
  ### Attribution:
779
790
 
@@ -858,7 +869,8 @@ interface FCPAttribution {
858
869
 
859
870
  #### `FIDAttribution`
860
871
 
861
- _This interface is deprecated and will be removed in next major release_
872
+ > [!CAUTION]
873
+ > This interface is deprecated and will be removed in the next major release.
862
874
 
863
875
  ```ts
864
876
  interface FIDAttribution {
@@ -1096,7 +1108,8 @@ The primary limitation of these APIs is they have no visibility into `<iframe>`
1096
1108
 
1097
1109
  For same-origin iframes, it's possible to use the `web-vitals` library to measure metrics, but it's tricky because it requires the developer to add the library to every frame and `postMessage()` the results to the parent frame for aggregation.
1098
1110
 
1099
- _**Note:** given the lack of iframe support, the `onCLS()` function technically measures [DCLS](https://github.com/wicg/layout-instability#cumulative-scores) (Document Cumulative Layout Shift) rather than CLS, if the page includes iframes)._
1111
+ > [!NOTE]
1112
+ > Given the lack of iframe support, the `onCLS()` function technically measures [DCLS](https://github.com/wicg/layout-instability#cumulative-scores) (Document Cumulative Layout Shift) rather than CLS, if the page includes iframes).
1100
1113
 
1101
1114
  ## Development
1102
1115
 
@@ -1,5 +1,6 @@
1
- import { INPMetricWithAttribution, ReportOpts } from '../types.js';
1
+ import { INPMetric, INPMetricWithAttribution, ReportOpts } from '../types.js';
2
2
  export declare const interactionTargetMap: Map<number, Node>;
3
+ export declare const attributeINP: (metric: INPMetric) => INPMetricWithAttribution;
3
4
  /**
4
5
  * Calculates the [INP](https://web.dev/articles/inp) value for the current
5
6
  * page and calls the `callback` function once the value is ready, along with
@@ -39,7 +39,7 @@ let pendingLoAFs = [];
39
39
  // that are known to not match INP are removed.
40
40
  let pendingEntriesGroups = [];
41
41
  // The `processingEnd` time of most recently-processed event, chronologically.
42
- let latestProcessingEnd;
42
+ let latestProcessingEnd = 0;
43
43
  // A WeakMap to look up the event-timing-entries group of a given entry.
44
44
  // Note that this only maps from "important" entries: either the first input or
45
45
  // those with an `interactionId`.
@@ -139,7 +139,7 @@ const cleanupEntries = () => {
139
139
  });
140
140
  // Keep all pending LoAF entries that either:
141
141
  // 1) intersect with entries in the newly cleaned up `pendingEntriesGroups`
142
- // 2) occur after the most recently-processed event entry.
142
+ // 2) occur after the most recently-processed event entry (for up to MAX_PREVIOUS_FRAMES)
143
143
  const loafsToKeep = new Set();
144
144
  for (let i = 0; i < pendingEntriesGroups.length; i++) {
145
145
  const group = pendingEntriesGroups[i];
@@ -147,16 +147,14 @@ const cleanupEntries = () => {
147
147
  loafsToKeep.add(loaf);
148
148
  });
149
149
  }
150
- for (let i = 0; i < MAX_PREVIOUS_FRAMES; i++) {
151
- // Look at pending LoAF in reverse order so the most recent are first.
152
- const loaf = pendingLoAFs[pendingLoAFs.length - 1 - i];
153
- // If we reach LoAFs that overlap with event processing,
154
- // we can assume all previous ones have already been handled.
155
- if (!loaf || loaf.startTime < latestProcessingEnd)
156
- break;
157
- loafsToKeep.add(loaf);
158
- }
159
- pendingLoAFs = Array.from(loafsToKeep);
150
+ const prevFrameIndexCutoff = pendingLoAFs.length - 1 - MAX_PREVIOUS_FRAMES;
151
+ // Filter `pendingLoAFs` to preserve LoAF order.
152
+ pendingLoAFs = pendingLoAFs.filter((loaf, index) => {
153
+ if (loaf.startTime > latestProcessingEnd && index > prevFrameIndexCutoff) {
154
+ return true;
155
+ }
156
+ return loafsToKeep.has(loaf);
157
+ });
160
158
  // Reset the idle callback handle so it can be queued again.
161
159
  idleHandle = -1;
162
160
  };
@@ -176,7 +174,7 @@ const getIntersectingLoAFs = (start, end) => {
176
174
  }
177
175
  return intersectingLoAFs;
178
176
  };
179
- const attributeINP = (metric) => {
177
+ export const attributeINP = (metric) => {
180
178
  const firstEntry = metric.entries[0];
181
179
  const group = entryToEntriesGroupMap.get(firstEntry);
182
180
  const processingStart = firstEntry.processingStart;
@@ -1,26 +1,6 @@
1
1
  import { MetricType, MetricRatingThresholds } from '../types.js';
2
- export declare const bindReporter: <MetricName extends "CLS" | "FCP" | "FID" | "INP" | "LCP" | "TTFB">(callback: (metric: Extract<import("../types.js").CLSMetric, {
2
+ export declare const bindReporter: <MetricName extends MetricType["name"]>(callback: (metric: Extract<MetricType, {
3
3
  name: MetricName;
4
- }> | Extract<import("../types.js").FCPMetric, {
5
- name: MetricName;
6
- }> | Extract<import("../types.js").FIDMetric, {
7
- name: MetricName;
8
- }> | Extract<import("../types.js").INPMetric, {
9
- name: MetricName;
10
- }> | Extract<import("../types.js").LCPMetric, {
11
- name: MetricName;
12
- }> | Extract<import("../types.js").TTFBMetric, {
13
- name: MetricName;
14
- }>) => void, metric: Extract<import("../types.js").CLSMetric, {
15
- name: MetricName;
16
- }> | Extract<import("../types.js").FCPMetric, {
17
- name: MetricName;
18
- }> | Extract<import("../types.js").FIDMetric, {
19
- name: MetricName;
20
- }> | Extract<import("../types.js").INPMetric, {
21
- name: MetricName;
22
- }> | Extract<import("../types.js").LCPMetric, {
23
- name: MetricName;
24
- }> | Extract<import("../types.js").TTFBMetric, {
4
+ }>) => void, metric: Extract<MetricType, {
25
5
  name: MetricName;
26
6
  }>, thresholds: MetricRatingThresholds, reportAllChanges?: boolean) => (forceReport?: boolean) => void;
@@ -1,4 +1,5 @@
1
- export declare const initMetric: <MetricName extends "CLS" | "FCP" | "FID" | "INP" | "LCP" | "TTFB">(name: MetricName, value?: number) => {
1
+ import { MetricType } from '../types.js';
2
+ export declare const initMetric: <MetricName extends MetricType["name"]>(name: MetricName, value?: number) => {
2
3
  name: MetricName;
3
4
  value: number;
4
5
  rating: "good";
@@ -17,5 +18,5 @@ export declare const initMetric: <MetricName extends "CLS" | "FCP" | "FID" | "IN
17
18
  name: MetricName;
18
19
  }>)["entries"];
19
20
  id: string;
20
- navigationType: "navigate" | "reload" | "back-forward" | "back-forward-cache" | "prerender" | "restore";
21
+ navigationType: "reload" | "navigate" | "prerender" | "back-forward" | "back-forward-cache" | "restore";
21
22
  };
@@ -34,7 +34,7 @@ const getInteractionCountForNavigation = () => {
34
34
  return getInteractionCount() - prevInteractionCount;
35
35
  };
36
36
  export const resetInteractions = () => {
37
- prevInteractionCount = 0;
37
+ prevInteractionCount = getInteractionCount();
38
38
  longestInteractionList.length = 0;
39
39
  longestInteractionMap.clear();
40
40
  };
@@ -84,7 +84,10 @@ export const onLCP = (onReport, opts) => {
84
84
  // Wrap in a setTimeout so the callback is run in a separate task
85
85
  // to avoid extending the keyboard/click handler to reduce INP impact
86
86
  // https://github.com/GoogleChrome/web-vitals/issues/383
87
- addEventListener(type, () => whenIdle(stopListening), true);
87
+ addEventListener(type, () => whenIdle(stopListening), {
88
+ once: true,
89
+ capture: true,
90
+ });
88
91
  });
89
92
  onHidden(stopListening);
90
93
  // Only report after a bfcache restore if the `PerformanceObserver`
@@ -1 +1 @@
1
- var webVitals=function(t){"use strict";var e,n,r,i=function(){var t=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},a=function(t){if("loading"===document.readyState)return"loading";var e=i();if(e){if(t<e.domInteractive)return"loading";if(0===e.domContentLoadedEventStart||t<e.domContentLoadedEventStart)return"dom-interactive";if(0===e.domComplete||t<e.domComplete)return"dom-content-loaded"}return"complete"},o=function(t){var e=t.nodeName;return 1===t.nodeType?e.toLowerCase():e.toUpperCase().replace(/^#/,"")},c=function(t,e){var n="";try{for(;t&&9!==t.nodeType;){var r=t,i=r.id?"#"+r.id:o(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+i.length>(e||100)-1)return n||i;if(n=n?i+">"+n:i,r.id)break;t=r.parentNode}}catch(t){}return n},s=-1,u=function(){return s},f=function(t){addEventListener("pageshow",(function(e){e.persisted&&(s=e.timeStamp,t(e))}),!0)},d=function(){var t=i();return t&&t.activationStart||0},l=function(t,e){var n=i(),r="navigate";u()>=0?r="back-forward-cache":n&&(document.prerendering||d()>0?r="prerender":document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-")));return{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},m=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},v=function(t,e,n,r){var i,a;return function(o){e.value>=0&&(o||r)&&((a=e.value-(i||0))||void 0===i)&&(i=e.value,e.delta=a,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},p=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},h=function(t){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&t()}))},g=function(t){var e=!1;return function(){e||(t(),e=!0)}},T=-1,y=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},E=function(t){"hidden"===document.visibilityState&&T>-1&&(T="visibilitychange"===t.type?t.timeStamp:0,b())},S=function(){addEventListener("visibilitychange",E,!0),addEventListener("prerenderingchange",E,!0)},b=function(){removeEventListener("visibilitychange",E,!0),removeEventListener("prerenderingchange",E,!0)},C=function(){return T<0&&(T=y(),S(),f((function(){setTimeout((function(){T=y(),S()}),0)}))),{get firstHiddenTime(){return T}}},L=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},M=[1800,3e3],D=function(t,e){e=e||{},L((function(){var n,r=C(),i=l("FCP"),a=m("paint",(function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(a.disconnect(),t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-d(),0),i.entries.push(t),n(!0)))}))}));a&&(n=v(t,i,M,e.reportAllChanges),f((function(r){i=l("FCP"),n=v(t,i,M,e.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))},w=[.1,.25],I=0,F=1/0,P=0,k=function(t){t.forEach((function(t){t.interactionId&&(F=Math.min(F,t.interactionId),P=Math.max(P,t.interactionId),I=P?(P-F)/7+1:0)}))},x=function(){"interactionCount"in performance||e||(e=m("event",k,{type:"event",buffered:!0,durationThreshold:0}))},A=[],B=new Map,O=0,R=function(){return(e?I:performance.interactionCount||0)-O},j=[],q=function(t){if(j.forEach((function(e){return e(t)})),t.interactionId||"first-input"===t.entryType){var e=A[A.length-1],n=B.get(t.interactionId);if(n||A.length<10||t.duration>e.latency){if(n)t.duration>n.latency?(n.entries=[t],n.latency=t.duration):t.duration===n.latency&&t.startTime===n.entries[0].startTime&&n.entries.push(t);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};B.set(r.id,r),A.push(r)}A.sort((function(t,e){return e.latency-t.latency})),A.length>10&&A.splice(10).forEach((function(t){return B.delete(t.id)}))}}},N=function(t){var e=self.requestIdleCallback||self.setTimeout,n=-1;return t=g(t),"hidden"===document.visibilityState?t():(n=e(t),h(t)),n},H=[200,500],V=function(t,e){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(e=e||{},L((function(){var n;x();var r,i=l("INP"),a=function(t){N((function(){t.forEach(q);var e,n=(e=Math.min(A.length-1,Math.floor(R()/50)),A[e]);n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},o=m("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=v(t,i,H,e.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),h((function(){a(o.takeRecords()),r(!0)})),f((function(){O=0,A.length=0,B.clear(),i=l("INP"),r=v(t,i,H,e.reportAllChanges)})))})))},W=[],z=[],U=new WeakMap,_=new Map,G=-1,J=function(t){W=W.concat(t),K()},K=function(){G<0&&(G=N(Q))},Q=function(){_.size>10&&_.forEach((function(t,e){B.has(e)||_.delete(e)}));var t=A.map((function(t){return U.get(t.entries[0])})),e=z.length-50;z=z.filter((function(n,r){return r>=e||t.includes(n)}));for(var n=new Set,i=0;i<z.length;i++){var a=z[i];tt(a.startTime,a.processingEnd).forEach((function(t){n.add(t)}))}for(var o=0;o<50;o++){var c=W[W.length-1-o];if(!c||c.startTime<r)break;n.add(c)}W=Array.from(n),G=-1};j.push((function(t){t.interactionId&&t.target&&!_.has(t.interactionId)&&_.set(t.interactionId,t.target)}),(function(t){var e,n=t.startTime+t.duration;r=Math.max(r,t.processingEnd);for(var i=z.length-1;i>=0;i--){var a=z[i];if(Math.abs(n-a.renderTime)<=8){(e=a).startTime=Math.min(t.startTime,e.startTime),e.processingStart=Math.min(t.processingStart,e.processingStart),e.processingEnd=Math.max(t.processingEnd,e.processingEnd),e.entries.push(t);break}}e||(e={startTime:t.startTime,processingStart:t.processingStart,processingEnd:t.processingEnd,renderTime:n,entries:[t]},z.push(e)),(t.interactionId||"first-input"===t.entryType)&&U.set(t,e),K()}));var X,Y,Z,$,tt=function(t,e){for(var n,r=[],i=0;n=W[i];i++)if(!(n.startTime+n.duration<t)){if(n.startTime>e)break;r.push(n)}return r},et=[2500,4e3],nt={},rt=[800,1800],it=function t(e){document.prerendering?L((function(){return t(e)})):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)},at=function(t,e){e=e||{};var n=l("TTFB"),r=v(t,n,rt,e.reportAllChanges);it((function(){var a=i();a&&(n.value=Math.max(a.responseStart-d(),0),n.entries=[a],r(!0),f((function(){n=l("TTFB",0),(r=v(t,n,rt,e.reportAllChanges))(!0)})))}))},ot={passive:!0,capture:!0},ct=new Date,st=function(t,e){X||(X=e,Y=t,Z=new Date,dt(removeEventListener),ut())},ut=function(){if(Y>=0&&Y<Z-ct){var t={entryType:"first-input",name:X.type,target:X.target,cancelable:X.cancelable,startTime:X.timeStamp,processingStart:X.timeStamp+Y};$.forEach((function(e){e(t)})),$=[]}},ft=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){st(t,e),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,ot),removeEventListener("pointercancel",r,ot)};addEventListener("pointerup",n,ot),addEventListener("pointercancel",r,ot)}(e,t):st(e,t)}},dt=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,ft,ot)}))},lt=[100,300],mt=function(t,e){e=e||{},L((function(){var n,r=C(),i=l("FID"),a=function(t){t.startTime<r.firstHiddenTime&&(i.value=t.processingStart-t.startTime,i.entries.push(t),n(!0))},o=function(t){t.forEach(a)},c=m("first-input",o);n=v(t,i,lt,e.reportAllChanges),c&&(h(g((function(){o(c.takeRecords()),c.disconnect()}))),f((function(){var r;i=l("FID"),n=v(t,i,lt,e.reportAllChanges),$=[],Y=-1,X=null,dt(addEventListener),r=a,$.push(r),ut()})))}))};return t.CLSThresholds=w,t.FCPThresholds=M,t.FIDThresholds=lt,t.INPThresholds=H,t.LCPThresholds=et,t.TTFBThresholds=rt,t.onCLS=function(t,e){!function(t,e){e=e||{},D(g((function(){var n,r=l("CLS",0),i=0,a=[],o=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=a[0],n=a[a.length-1];i&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(i+=t.value,a.push(t)):(i=t.value,a=[t])}})),i>r.value&&(r.value=i,r.entries=a,n())},c=m("layout-shift",o);c&&(n=v(t,r,w,e.reportAllChanges),h((function(){o(c.takeRecords()),n(!0)})),f((function(){i=0,r=l("CLS",0),n=v(t,r,w,e.reportAllChanges),p((function(){return n()}))})),setTimeout(n,0))})))}((function(e){var n=function(t){var e,n={};if(t.entries.length){var r=t.entries.reduce((function(t,e){return t&&t.value>e.value?t:e}));if(r&&r.sources&&r.sources.length){var i=(e=r.sources).find((function(t){return t.node&&1===t.node.nodeType}))||e[0];i&&(n={largestShiftTarget:c(i.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:i,largestShiftEntry:r,loadState:a(r.startTime)})}}return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onFCP=function(t,e){D((function(e){var n=function(t){var e={timeToFirstByte:0,firstByteToFCP:t.value,loadState:a(u())};if(t.entries.length){var n=i(),r=t.entries[t.entries.length-1];if(n){var o=n.activationStart||0,c=Math.max(0,n.responseStart-o);e={timeToFirstByte:c,firstByteToFCP:t.value-c,loadState:a(t.entries[0].startTime),navigationEntry:n,fcpEntry:r}}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onFID=function(t,e){mt((function(e){var n=function(t){var e=t.entries[0],n={eventTarget:c(e.target),eventType:e.name,eventTime:e.startTime,eventEntry:e,loadState:a(e.startTime)};return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onINP=function(t,e){n||(n=m("long-animation-frame",J)),V((function(e){var n=function(t){var e=t.entries[0],n=U.get(e),r=e.processingStart,i=n.processingEnd,o=n.entries.sort((function(t,e){return t.processingStart-e.processingStart})),s=tt(e.startTime,i),u=t.entries.find((function(t){return t.target})),f=u&&u.target||_.get(e.interactionId),d=[e.startTime+e.duration,i].concat(s.map((function(t){return t.startTime+t.duration}))),l=Math.max.apply(Math,d),m={interactionTarget:c(f),interactionTargetElement:f,interactionType:e.name.startsWith("key")?"keyboard":"pointer",interactionTime:e.startTime,nextPaintTime:l,processedEventEntries:o,longAnimationFrameEntries:s,inputDelay:r-e.startTime,processingDuration:i-r,presentationDelay:Math.max(l-i,0),loadState:a(e.startTime)};return Object.assign(t,{attribution:m})}(e);t(n)}),e)},t.onLCP=function(t,e){!function(t,e){e=e||{},L((function(){var n,r=C(),i=l("LCP"),a=function(t){e.reportAllChanges||(t=t.slice(-1)),t.forEach((function(t){t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-d(),0),i.entries=[t],n())}))},o=m("largest-contentful-paint",a);if(o){n=v(t,i,et,e.reportAllChanges);var c=g((function(){nt[i.id]||(a(o.takeRecords()),o.disconnect(),nt[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(t){addEventListener(t,(function(){return N(c)}),!0)})),h(c),f((function(r){i=l("LCP"),n=v(t,i,et,e.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,nt[i.id]=!0,n(!0)}))}))}}))}((function(e){var n=function(t){var e={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:t.value};if(t.entries.length){var n=i();if(n){var r=n.activationStart||0,a=t.entries[t.entries.length-1],o=a.url&&performance.getEntriesByType("resource").filter((function(t){return t.name===a.url}))[0],s=Math.max(0,n.responseStart-r),u=Math.max(s,o?(o.requestStart||o.startTime)-r:0),f=Math.max(u,o?o.responseEnd-r:0),d=Math.max(f,a.startTime-r);e={element:c(a.element),timeToFirstByte:s,resourceLoadDelay:u-s,resourceLoadDuration:f-u,elementRenderDelay:d-f,navigationEntry:n,lcpEntry:a},a.url&&(e.url=a.url),o&&(e.lcpResourceEntry=o)}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onTTFB=function(t,e){at((function(e){var n=function(t){var e={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(t.entries.length){var n=t.entries[0],r=n.activationStart||0,i=Math.max((n.workerStart||n.fetchStart)-r,0),a=Math.max(n.domainLookupStart-r,0),o=Math.max(n.connectStart-r,0),c=Math.max(n.connectEnd-r,0);e={waitingDuration:i,cacheDuration:a-i,dnsDuration:o-a,connectionDuration:c-o,requestDuration:t.value-c,navigationEntry:n}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t}({});
1
+ var webVitals=function(t){"use strict";var e,n,r=function(){var t=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},i=function(t){if("loading"===document.readyState)return"loading";var e=r();if(e){if(t<e.domInteractive)return"loading";if(0===e.domContentLoadedEventStart||t<e.domContentLoadedEventStart)return"dom-interactive";if(0===e.domComplete||t<e.domComplete)return"dom-content-loaded"}return"complete"},a=function(t){var e=t.nodeName;return 1===t.nodeType?e.toLowerCase():e.toUpperCase().replace(/^#/,"")},o=function(t,e){var n="";try{for(;t&&9!==t.nodeType;){var r=t,i=r.id?"#"+r.id:a(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+i.length>(e||100)-1)return n||i;if(n=n?i+">"+n:i,r.id)break;t=r.parentNode}}catch(t){}return n},c=-1,s=function(){return c},u=function(t){addEventListener("pageshow",(function(e){e.persisted&&(c=e.timeStamp,t(e))}),!0)},f=function(){var t=r();return t&&t.activationStart||0},d=function(t,e){var n=r(),i="navigate";s()>=0?i="back-forward-cache":n&&(document.prerendering||f()>0?i="prerender":document.wasDiscarded?i="restore":n.type&&(i=n.type.replace(/_/g,"-")));return{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:i}},l=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},m=function(t,e,n,r){var i,a;return function(o){e.value>=0&&(o||r)&&((a=e.value-(i||0))||void 0===i)&&(i=e.value,e.delta=a,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},v=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},p=function(t){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&t()}))},h=function(t){var e=!1;return function(){e||(t(),e=!0)}},g=-1,T=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},y=function(t){"hidden"===document.visibilityState&&g>-1&&(g="visibilitychange"===t.type?t.timeStamp:0,S())},E=function(){addEventListener("visibilitychange",y,!0),addEventListener("prerenderingchange",y,!0)},S=function(){removeEventListener("visibilitychange",y,!0),removeEventListener("prerenderingchange",y,!0)},b=function(){return g<0&&(g=T(),E(),u((function(){setTimeout((function(){g=T(),E()}),0)}))),{get firstHiddenTime(){return g}}},C=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},L=[1800,3e3],M=function(t,e){e=e||{},C((function(){var n,r=b(),i=d("FCP"),a=l("paint",(function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(a.disconnect(),t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-f(),0),i.entries.push(t),n(!0)))}))}));a&&(n=m(t,i,L,e.reportAllChanges),u((function(r){i=d("FCP"),n=m(t,i,L,e.reportAllChanges),v((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))},D=[.1,.25],w=0,I=1/0,F=0,P=function(t){t.forEach((function(t){t.interactionId&&(I=Math.min(I,t.interactionId),F=Math.max(F,t.interactionId),w=F?(F-I)/7+1:0)}))},x=function(){return e?w:performance.interactionCount||0},k=function(){"interactionCount"in performance||e||(e=l("event",P,{type:"event",buffered:!0,durationThreshold:0}))},A=[],B=new Map,O=0,R=function(){var t=Math.min(A.length-1,Math.floor((x()-O)/50));return A[t]},j=[],q=function(t){if(j.forEach((function(e){return e(t)})),t.interactionId||"first-input"===t.entryType){var e=A[A.length-1],n=B.get(t.interactionId);if(n||A.length<10||t.duration>e.latency){if(n)t.duration>n.latency?(n.entries=[t],n.latency=t.duration):t.duration===n.latency&&t.startTime===n.entries[0].startTime&&n.entries.push(t);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};B.set(r.id,r),A.push(r)}A.sort((function(t,e){return e.latency-t.latency})),A.length>10&&A.splice(10).forEach((function(t){return B.delete(t.id)}))}}},N=function(t){var e=self.requestIdleCallback||self.setTimeout,n=-1;return t=h(t),"hidden"===document.visibilityState?t():(n=e(t),p(t)),n},H=[200,500],V=function(t,e){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(e=e||{},C((function(){var n;k();var r,i=d("INP"),a=function(t){N((function(){t.forEach(q);var e=R();e&&e.latency!==i.value&&(i.value=e.latency,i.entries=e.entries,r())}))},o=l("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=m(t,i,H,e.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),p((function(){a(o.takeRecords()),r(!0)})),u((function(){O=x(),A.length=0,B.clear(),i=d("INP"),r=m(t,i,H,e.reportAllChanges)})))})))},W=[],z=[],U=0,_=new WeakMap,G=new Map,J=-1,K=function(t){W=W.concat(t),Q()},Q=function(){J<0&&(J=N(X))},X=function(){G.size>10&&G.forEach((function(t,e){B.has(e)||G.delete(e)}));var t=A.map((function(t){return _.get(t.entries[0])})),e=z.length-50;z=z.filter((function(n,r){return r>=e||t.includes(n)}));for(var n=new Set,r=0;r<z.length;r++){var i=z[r];et(i.startTime,i.processingEnd).forEach((function(t){n.add(t)}))}var a=W.length-1-50;W=W.filter((function(t,e){return t.startTime>U&&e>a||n.has(t)})),J=-1};j.push((function(t){t.interactionId&&t.target&&!G.has(t.interactionId)&&G.set(t.interactionId,t.target)}),(function(t){var e,n=t.startTime+t.duration;U=Math.max(U,t.processingEnd);for(var r=z.length-1;r>=0;r--){var i=z[r];if(Math.abs(n-i.renderTime)<=8){(e=i).startTime=Math.min(t.startTime,e.startTime),e.processingStart=Math.min(t.processingStart,e.processingStart),e.processingEnd=Math.max(t.processingEnd,e.processingEnd),e.entries.push(t);break}}e||(e={startTime:t.startTime,processingStart:t.processingStart,processingEnd:t.processingEnd,renderTime:n,entries:[t]},z.push(e)),(t.interactionId||"first-input"===t.entryType)&&_.set(t,e),Q()}));var Y,Z,$,tt,et=function(t,e){for(var n,r=[],i=0;n=W[i];i++)if(!(n.startTime+n.duration<t)){if(n.startTime>e)break;r.push(n)}return r},nt=[2500,4e3],rt={},it=[800,1800],at=function t(e){document.prerendering?C((function(){return t(e)})):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)},ot=function(t,e){e=e||{};var n=d("TTFB"),i=m(t,n,it,e.reportAllChanges);at((function(){var a=r();a&&(n.value=Math.max(a.responseStart-f(),0),n.entries=[a],i(!0),u((function(){n=d("TTFB",0),(i=m(t,n,it,e.reportAllChanges))(!0)})))}))},ct={passive:!0,capture:!0},st=new Date,ut=function(t,e){Y||(Y=e,Z=t,$=new Date,lt(removeEventListener),ft())},ft=function(){if(Z>=0&&Z<$-st){var t={entryType:"first-input",name:Y.type,target:Y.target,cancelable:Y.cancelable,startTime:Y.timeStamp,processingStart:Y.timeStamp+Z};tt.forEach((function(e){e(t)})),tt=[]}},dt=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){ut(t,e),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,ct),removeEventListener("pointercancel",r,ct)};addEventListener("pointerup",n,ct),addEventListener("pointercancel",r,ct)}(e,t):ut(e,t)}},lt=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,dt,ct)}))},mt=[100,300],vt=function(t,e){e=e||{},C((function(){var n,r=b(),i=d("FID"),a=function(t){t.startTime<r.firstHiddenTime&&(i.value=t.processingStart-t.startTime,i.entries.push(t),n(!0))},o=function(t){t.forEach(a)},c=l("first-input",o);n=m(t,i,mt,e.reportAllChanges),c&&(p(h((function(){o(c.takeRecords()),c.disconnect()}))),u((function(){var r;i=d("FID"),n=m(t,i,mt,e.reportAllChanges),tt=[],Z=-1,Y=null,lt(addEventListener),r=a,tt.push(r),ft()})))}))};return t.CLSThresholds=D,t.FCPThresholds=L,t.FIDThresholds=mt,t.INPThresholds=H,t.LCPThresholds=nt,t.TTFBThresholds=it,t.onCLS=function(t,e){!function(t,e){e=e||{},M(h((function(){var n,r=d("CLS",0),i=0,a=[],o=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=a[0],n=a[a.length-1];i&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(i+=t.value,a.push(t)):(i=t.value,a=[t])}})),i>r.value&&(r.value=i,r.entries=a,n())},c=l("layout-shift",o);c&&(n=m(t,r,D,e.reportAllChanges),p((function(){o(c.takeRecords()),n(!0)})),u((function(){i=0,r=d("CLS",0),n=m(t,r,D,e.reportAllChanges),v((function(){return n()}))})),setTimeout(n,0))})))}((function(e){var n=function(t){var e,n={};if(t.entries.length){var r=t.entries.reduce((function(t,e){return t&&t.value>e.value?t:e}));if(r&&r.sources&&r.sources.length){var a=(e=r.sources).find((function(t){return t.node&&1===t.node.nodeType}))||e[0];a&&(n={largestShiftTarget:o(a.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:a,largestShiftEntry:r,loadState:i(r.startTime)})}}return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onFCP=function(t,e){M((function(e){var n=function(t){var e={timeToFirstByte:0,firstByteToFCP:t.value,loadState:i(s())};if(t.entries.length){var n=r(),a=t.entries[t.entries.length-1];if(n){var o=n.activationStart||0,c=Math.max(0,n.responseStart-o);e={timeToFirstByte:c,firstByteToFCP:t.value-c,loadState:i(t.entries[0].startTime),navigationEntry:n,fcpEntry:a}}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onFID=function(t,e){vt((function(e){var n=function(t){var e=t.entries[0],n={eventTarget:o(e.target),eventType:e.name,eventTime:e.startTime,eventEntry:e,loadState:i(e.startTime)};return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onINP=function(t,e){n||(n=l("long-animation-frame",K)),V((function(e){var n=function(t){var e=t.entries[0],n=_.get(e),r=e.processingStart,a=n.processingEnd,c=n.entries.sort((function(t,e){return t.processingStart-e.processingStart})),s=et(e.startTime,a),u=t.entries.find((function(t){return t.target})),f=u&&u.target||G.get(e.interactionId),d=[e.startTime+e.duration,a].concat(s.map((function(t){return t.startTime+t.duration}))),l=Math.max.apply(Math,d),m={interactionTarget:o(f),interactionTargetElement:f,interactionType:e.name.startsWith("key")?"keyboard":"pointer",interactionTime:e.startTime,nextPaintTime:l,processedEventEntries:c,longAnimationFrameEntries:s,inputDelay:r-e.startTime,processingDuration:a-r,presentationDelay:Math.max(l-a,0),loadState:i(e.startTime)};return Object.assign(t,{attribution:m})}(e);t(n)}),e)},t.onLCP=function(t,e){!function(t,e){e=e||{},C((function(){var n,r=b(),i=d("LCP"),a=function(t){e.reportAllChanges||(t=t.slice(-1)),t.forEach((function(t){t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-f(),0),i.entries=[t],n())}))},o=l("largest-contentful-paint",a);if(o){n=m(t,i,nt,e.reportAllChanges);var c=h((function(){rt[i.id]||(a(o.takeRecords()),o.disconnect(),rt[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(t){addEventListener(t,(function(){return N(c)}),{once:!0,capture:!0})})),p(c),u((function(r){i=d("LCP"),n=m(t,i,nt,e.reportAllChanges),v((function(){i.value=performance.now()-r.timeStamp,rt[i.id]=!0,n(!0)}))}))}}))}((function(e){var n=function(t){var e={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:t.value};if(t.entries.length){var n=r();if(n){var i=n.activationStart||0,a=t.entries[t.entries.length-1],c=a.url&&performance.getEntriesByType("resource").filter((function(t){return t.name===a.url}))[0],s=Math.max(0,n.responseStart-i),u=Math.max(s,c?(c.requestStart||c.startTime)-i:0),f=Math.max(u,c?c.responseEnd-i:0),d=Math.max(f,a.startTime-i);e={element:o(a.element),timeToFirstByte:s,resourceLoadDelay:u-s,resourceLoadDuration:f-u,elementRenderDelay:d-f,navigationEntry:n,lcpEntry:a},a.url&&(e.url=a.url),c&&(e.lcpResourceEntry=c)}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onTTFB=function(t,e){ot((function(e){var n=function(t){var e={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(t.entries.length){var n=t.entries[0],r=n.activationStart||0,i=Math.max((n.workerStart||n.fetchStart)-r,0),a=Math.max(n.domainLookupStart-r,0),o=Math.max(n.connectStart-r,0),c=Math.max(n.connectEnd-r,0);e={waitingDuration:i,cacheDuration:a-i,dnsDuration:o-a,connectionDuration:c-o,requestDuration:t.value-c,navigationEntry:n}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t}({});
@@ -1 +1 @@
1
- var t,e,n,r=function(){var t=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},i=function(t){if("loading"===document.readyState)return"loading";var e=r();if(e){if(t<e.domInteractive)return"loading";if(0===e.domContentLoadedEventStart||t<e.domContentLoadedEventStart)return"dom-interactive";if(0===e.domComplete||t<e.domComplete)return"dom-content-loaded"}return"complete"},a=function(t){var e=t.nodeName;return 1===t.nodeType?e.toLowerCase():e.toUpperCase().replace(/^#/,"")},o=function(t,e){var n="";try{for(;t&&9!==t.nodeType;){var r=t,i=r.id?"#"+r.id:a(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+i.length>(e||100)-1)return n||i;if(n=n?i+">"+n:i,r.id)break;t=r.parentNode}}catch(t){}return n},c=-1,u=function(){return c},s=function(t){addEventListener("pageshow",(function(e){e.persisted&&(c=e.timeStamp,t(e))}),!0)},f=function(){var t=r();return t&&t.activationStart||0},d=function(t,e){var n=r(),i="navigate";u()>=0?i="back-forward-cache":n&&(document.prerendering||f()>0?i="prerender":document.wasDiscarded?i="restore":n.type&&(i=n.type.replace(/_/g,"-")));return{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:i}},l=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},m=function(t,e,n,r){var i,a;return function(o){e.value>=0&&(o||r)&&((a=e.value-(i||0))||void 0===i)&&(i=e.value,e.delta=a,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},p=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},v=function(t){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&t()}))},g=function(t){var e=!1;return function(){e||(t(),e=!0)}},h=-1,T=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},y=function(t){"hidden"===document.visibilityState&&h>-1&&(h="visibilitychange"===t.type?t.timeStamp:0,S())},E=function(){addEventListener("visibilitychange",y,!0),addEventListener("prerenderingchange",y,!0)},S=function(){removeEventListener("visibilitychange",y,!0),removeEventListener("prerenderingchange",y,!0)},b=function(){return h<0&&(h=T(),E(),s((function(){setTimeout((function(){h=T(),E()}),0)}))),{get firstHiddenTime(){return h}}},L=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},C=[1800,3e3],M=function(t,e){e=e||{},L((function(){var n,r=b(),i=d("FCP"),a=l("paint",(function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(a.disconnect(),t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-f(),0),i.entries.push(t),n(!0)))}))}));a&&(n=m(t,i,C,e.reportAllChanges),s((function(r){i=d("FCP"),n=m(t,i,C,e.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))},D=[.1,.25],w=function(t,e){!function(t,e){e=e||{},M(g((function(){var n,r=d("CLS",0),i=0,a=[],o=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=a[0],n=a[a.length-1];i&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(i+=t.value,a.push(t)):(i=t.value,a=[t])}})),i>r.value&&(r.value=i,r.entries=a,n())},c=l("layout-shift",o);c&&(n=m(t,r,D,e.reportAllChanges),v((function(){o(c.takeRecords()),n(!0)})),s((function(){i=0,r=d("CLS",0),n=m(t,r,D,e.reportAllChanges),p((function(){return n()}))})),setTimeout(n,0))})))}((function(e){var n=function(t){var e,n={};if(t.entries.length){var r=t.entries.reduce((function(t,e){return t&&t.value>e.value?t:e}));if(r&&r.sources&&r.sources.length){var a=(e=r.sources).find((function(t){return t.node&&1===t.node.nodeType}))||e[0];a&&(n={largestShiftTarget:o(a.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:a,largestShiftEntry:r,loadState:i(r.startTime)})}}return Object.assign(t,{attribution:n})}(e);t(n)}),e)},x=function(t,e){M((function(e){var n=function(t){var e={timeToFirstByte:0,firstByteToFCP:t.value,loadState:i(u())};if(t.entries.length){var n=r(),a=t.entries[t.entries.length-1];if(n){var o=n.activationStart||0,c=Math.max(0,n.responseStart-o);e={timeToFirstByte:c,firstByteToFCP:t.value-c,loadState:i(t.entries[0].startTime),navigationEntry:n,fcpEntry:a}}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},I=0,k=1/0,A=0,F=function(t){t.forEach((function(t){t.interactionId&&(k=Math.min(k,t.interactionId),A=Math.max(A,t.interactionId),I=A?(A-k)/7+1:0)}))},P=function(){"interactionCount"in performance||t||(t=l("event",F,{type:"event",buffered:!0,durationThreshold:0}))},B=[],O=new Map,R=0,j=function(){return(t?I:performance.interactionCount||0)-R},q=[],H=function(t){if(q.forEach((function(e){return e(t)})),t.interactionId||"first-input"===t.entryType){var e=B[B.length-1],n=O.get(t.interactionId);if(n||B.length<10||t.duration>e.latency){if(n)t.duration>n.latency?(n.entries=[t],n.latency=t.duration):t.duration===n.latency&&t.startTime===n.entries[0].startTime&&n.entries.push(t);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};O.set(r.id,r),B.push(r)}B.sort((function(t,e){return e.latency-t.latency})),B.length>10&&B.splice(10).forEach((function(t){return O.delete(t.id)}))}}},N=function(t){var e=self.requestIdleCallback||self.setTimeout,n=-1;return t=g(t),"hidden"===document.visibilityState?t():(n=e(t),v(t)),n},W=[200,500],z=function(t,e){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(e=e||{},L((function(){var n;P();var r,i=d("INP"),a=function(t){N((function(){t.forEach(H);var e,n=(e=Math.min(B.length-1,Math.floor(j()/50)),B[e]);n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},o=l("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=m(t,i,W,e.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),v((function(){a(o.takeRecords()),r(!0)})),s((function(){R=0,B.length=0,O.clear(),i=d("INP"),r=m(t,i,W,e.reportAllChanges)})))})))},U=[],V=[],_=new WeakMap,G=new Map,J=-1,K=function(t){U=U.concat(t),Q()},Q=function(){J<0&&(J=N(X))},X=function(){G.size>10&&G.forEach((function(t,e){O.has(e)||G.delete(e)}));var t=B.map((function(t){return _.get(t.entries[0])})),e=V.length-50;V=V.filter((function(n,r){return r>=e||t.includes(n)}));for(var r=new Set,i=0;i<V.length;i++){var a=V[i];et(a.startTime,a.processingEnd).forEach((function(t){r.add(t)}))}for(var o=0;o<50;o++){var c=U[U.length-1-o];if(!c||c.startTime<n)break;r.add(c)}U=Array.from(r),J=-1};q.push((function(t){t.interactionId&&t.target&&!G.has(t.interactionId)&&G.set(t.interactionId,t.target)}),(function(t){var e,r=t.startTime+t.duration;n=Math.max(n,t.processingEnd);for(var i=V.length-1;i>=0;i--){var a=V[i];if(Math.abs(r-a.renderTime)<=8){(e=a).startTime=Math.min(t.startTime,e.startTime),e.processingStart=Math.min(t.processingStart,e.processingStart),e.processingEnd=Math.max(t.processingEnd,e.processingEnd),e.entries.push(t);break}}e||(e={startTime:t.startTime,processingStart:t.processingStart,processingEnd:t.processingEnd,renderTime:r,entries:[t]},V.push(e)),(t.interactionId||"first-input"===t.entryType)&&_.set(t,e),Q()}));var Y,Z,$,tt,et=function(t,e){for(var n,r=[],i=0;n=U[i];i++)if(!(n.startTime+n.duration<t)){if(n.startTime>e)break;r.push(n)}return r},nt=function(t,n){e||(e=l("long-animation-frame",K)),z((function(e){var n=function(t){var e=t.entries[0],n=_.get(e),r=e.processingStart,a=n.processingEnd,c=n.entries.sort((function(t,e){return t.processingStart-e.processingStart})),u=et(e.startTime,a),s=t.entries.find((function(t){return t.target})),f=s&&s.target||G.get(e.interactionId),d=[e.startTime+e.duration,a].concat(u.map((function(t){return t.startTime+t.duration}))),l=Math.max.apply(Math,d),m={interactionTarget:o(f),interactionTargetElement:f,interactionType:e.name.startsWith("key")?"keyboard":"pointer",interactionTime:e.startTime,nextPaintTime:l,processedEventEntries:c,longAnimationFrameEntries:u,inputDelay:r-e.startTime,processingDuration:a-r,presentationDelay:Math.max(l-a,0),loadState:i(e.startTime)};return Object.assign(t,{attribution:m})}(e);t(n)}),n)},rt=[2500,4e3],it={},at=function(t,e){!function(t,e){e=e||{},L((function(){var n,r=b(),i=d("LCP"),a=function(t){e.reportAllChanges||(t=t.slice(-1)),t.forEach((function(t){t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-f(),0),i.entries=[t],n())}))},o=l("largest-contentful-paint",a);if(o){n=m(t,i,rt,e.reportAllChanges);var c=g((function(){it[i.id]||(a(o.takeRecords()),o.disconnect(),it[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(t){addEventListener(t,(function(){return N(c)}),!0)})),v(c),s((function(r){i=d("LCP"),n=m(t,i,rt,e.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,it[i.id]=!0,n(!0)}))}))}}))}((function(e){var n=function(t){var e={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:t.value};if(t.entries.length){var n=r();if(n){var i=n.activationStart||0,a=t.entries[t.entries.length-1],c=a.url&&performance.getEntriesByType("resource").filter((function(t){return t.name===a.url}))[0],u=Math.max(0,n.responseStart-i),s=Math.max(u,c?(c.requestStart||c.startTime)-i:0),f=Math.max(s,c?c.responseEnd-i:0),d=Math.max(f,a.startTime-i);e={element:o(a.element),timeToFirstByte:u,resourceLoadDelay:s-u,resourceLoadDuration:f-s,elementRenderDelay:d-f,navigationEntry:n,lcpEntry:a},a.url&&(e.url=a.url),c&&(e.lcpResourceEntry=c)}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},ot=[800,1800],ct=function t(e){document.prerendering?L((function(){return t(e)})):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)},ut=function(t,e){e=e||{};var n=d("TTFB"),i=m(t,n,ot,e.reportAllChanges);ct((function(){var a=r();a&&(n.value=Math.max(a.responseStart-f(),0),n.entries=[a],i(!0),s((function(){n=d("TTFB",0),(i=m(t,n,ot,e.reportAllChanges))(!0)})))}))},st=function(t,e){ut((function(e){var n=function(t){var e={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(t.entries.length){var n=t.entries[0],r=n.activationStart||0,i=Math.max((n.workerStart||n.fetchStart)-r,0),a=Math.max(n.domainLookupStart-r,0),o=Math.max(n.connectStart-r,0),c=Math.max(n.connectEnd-r,0);e={waitingDuration:i,cacheDuration:a-i,dnsDuration:o-a,connectionDuration:c-o,requestDuration:t.value-c,navigationEntry:n}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},ft={passive:!0,capture:!0},dt=new Date,lt=function(t,e){Y||(Y=e,Z=t,$=new Date,vt(removeEventListener),mt())},mt=function(){if(Z>=0&&Z<$-dt){var t={entryType:"first-input",name:Y.type,target:Y.target,cancelable:Y.cancelable,startTime:Y.timeStamp,processingStart:Y.timeStamp+Z};tt.forEach((function(e){e(t)})),tt=[]}},pt=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){lt(t,e),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,ft),removeEventListener("pointercancel",r,ft)};addEventListener("pointerup",n,ft),addEventListener("pointercancel",r,ft)}(e,t):lt(e,t)}},vt=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,pt,ft)}))},gt=[100,300],ht=function(t,e){e=e||{},L((function(){var n,r=b(),i=d("FID"),a=function(t){t.startTime<r.firstHiddenTime&&(i.value=t.processingStart-t.startTime,i.entries.push(t),n(!0))},o=function(t){t.forEach(a)},c=l("first-input",o);n=m(t,i,gt,e.reportAllChanges),c&&(v(g((function(){o(c.takeRecords()),c.disconnect()}))),s((function(){var r;i=d("FID"),n=m(t,i,gt,e.reportAllChanges),tt=[],Z=-1,Y=null,vt(addEventListener),r=a,tt.push(r),mt()})))}))},Tt=function(t,e){ht((function(e){var n=function(t){var e=t.entries[0],n={eventTarget:o(e.target),eventType:e.name,eventTime:e.startTime,eventEntry:e,loadState:i(e.startTime)};return Object.assign(t,{attribution:n})}(e);t(n)}),e)};export{D as CLSThresholds,C as FCPThresholds,gt as FIDThresholds,W as INPThresholds,rt as LCPThresholds,ot as TTFBThresholds,w as onCLS,x as onFCP,Tt as onFID,nt as onINP,at as onLCP,st as onTTFB};
1
+ var t,e,n=function(){var t=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},r=function(t){if("loading"===document.readyState)return"loading";var e=n();if(e){if(t<e.domInteractive)return"loading";if(0===e.domContentLoadedEventStart||t<e.domContentLoadedEventStart)return"dom-interactive";if(0===e.domComplete||t<e.domComplete)return"dom-content-loaded"}return"complete"},i=function(t){var e=t.nodeName;return 1===t.nodeType?e.toLowerCase():e.toUpperCase().replace(/^#/,"")},a=function(t,e){var n="";try{for(;t&&9!==t.nodeType;){var r=t,a=r.id?"#"+r.id:i(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+a.length>(e||100)-1)return n||a;if(n=n?a+">"+n:a,r.id)break;t=r.parentNode}}catch(t){}return n},o=-1,c=function(){return o},u=function(t){addEventListener("pageshow",(function(e){e.persisted&&(o=e.timeStamp,t(e))}),!0)},s=function(){var t=n();return t&&t.activationStart||0},f=function(t,e){var r=n(),i="navigate";c()>=0?i="back-forward-cache":r&&(document.prerendering||s()>0?i="prerender":document.wasDiscarded?i="restore":r.type&&(i=r.type.replace(/_/g,"-")));return{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:i}},d=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},l=function(t,e,n,r){var i,a;return function(o){e.value>=0&&(o||r)&&((a=e.value-(i||0))||void 0===i)&&(i=e.value,e.delta=a,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},m=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},p=function(t){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&t()}))},v=function(t){var e=!1;return function(){e||(t(),e=!0)}},g=-1,h=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},T=function(t){"hidden"===document.visibilityState&&g>-1&&(g="visibilitychange"===t.type?t.timeStamp:0,E())},y=function(){addEventListener("visibilitychange",T,!0),addEventListener("prerenderingchange",T,!0)},E=function(){removeEventListener("visibilitychange",T,!0),removeEventListener("prerenderingchange",T,!0)},S=function(){return g<0&&(g=h(),y(),u((function(){setTimeout((function(){g=h(),y()}),0)}))),{get firstHiddenTime(){return g}}},b=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},L=[1800,3e3],C=function(t,e){e=e||{},b((function(){var n,r=S(),i=f("FCP"),a=d("paint",(function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(a.disconnect(),t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-s(),0),i.entries.push(t),n(!0)))}))}));a&&(n=l(t,i,L,e.reportAllChanges),u((function(r){i=f("FCP"),n=l(t,i,L,e.reportAllChanges),m((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))},M=[.1,.25],D=function(t,e){!function(t,e){e=e||{},C(v((function(){var n,r=f("CLS",0),i=0,a=[],o=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=a[0],n=a[a.length-1];i&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(i+=t.value,a.push(t)):(i=t.value,a=[t])}})),i>r.value&&(r.value=i,r.entries=a,n())},c=d("layout-shift",o);c&&(n=l(t,r,M,e.reportAllChanges),p((function(){o(c.takeRecords()),n(!0)})),u((function(){i=0,r=f("CLS",0),n=l(t,r,M,e.reportAllChanges),m((function(){return n()}))})),setTimeout(n,0))})))}((function(e){var n=function(t){var e,n={};if(t.entries.length){var i=t.entries.reduce((function(t,e){return t&&t.value>e.value?t:e}));if(i&&i.sources&&i.sources.length){var o=(e=i.sources).find((function(t){return t.node&&1===t.node.nodeType}))||e[0];o&&(n={largestShiftTarget:a(o.node),largestShiftTime:i.startTime,largestShiftValue:i.value,largestShiftSource:o,largestShiftEntry:i,loadState:r(i.startTime)})}}return Object.assign(t,{attribution:n})}(e);t(n)}),e)},w=function(t,e){C((function(e){var i=function(t){var e={timeToFirstByte:0,firstByteToFCP:t.value,loadState:r(c())};if(t.entries.length){var i=n(),a=t.entries[t.entries.length-1];if(i){var o=i.activationStart||0,u=Math.max(0,i.responseStart-o);e={timeToFirstByte:u,firstByteToFCP:t.value-u,loadState:r(t.entries[0].startTime),navigationEntry:i,fcpEntry:a}}}return Object.assign(t,{attribution:e})}(e);t(i)}),e)},x=0,I=1/0,k=0,A=function(t){t.forEach((function(t){t.interactionId&&(I=Math.min(I,t.interactionId),k=Math.max(k,t.interactionId),x=k?(k-I)/7+1:0)}))},F=function(){return t?x:performance.interactionCount||0},P=function(){"interactionCount"in performance||t||(t=d("event",A,{type:"event",buffered:!0,durationThreshold:0}))},B=[],O=new Map,R=0,j=function(){var t=Math.min(B.length-1,Math.floor((F()-R)/50));return B[t]},q=[],H=function(t){if(q.forEach((function(e){return e(t)})),t.interactionId||"first-input"===t.entryType){var e=B[B.length-1],n=O.get(t.interactionId);if(n||B.length<10||t.duration>e.latency){if(n)t.duration>n.latency?(n.entries=[t],n.latency=t.duration):t.duration===n.latency&&t.startTime===n.entries[0].startTime&&n.entries.push(t);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};O.set(r.id,r),B.push(r)}B.sort((function(t,e){return e.latency-t.latency})),B.length>10&&B.splice(10).forEach((function(t){return O.delete(t.id)}))}}},N=function(t){var e=self.requestIdleCallback||self.setTimeout,n=-1;return t=v(t),"hidden"===document.visibilityState?t():(n=e(t),p(t)),n},W=[200,500],z=function(t,e){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(e=e||{},b((function(){var n;P();var r,i=f("INP"),a=function(t){N((function(){t.forEach(H);var e=j();e&&e.latency!==i.value&&(i.value=e.latency,i.entries=e.entries,r())}))},o=d("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=l(t,i,W,e.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),p((function(){a(o.takeRecords()),r(!0)})),u((function(){R=F(),B.length=0,O.clear(),i=f("INP"),r=l(t,i,W,e.reportAllChanges)})))})))},U=[],V=[],_=0,G=new WeakMap,J=new Map,K=-1,Q=function(t){U=U.concat(t),X()},X=function(){K<0&&(K=N(Y))},Y=function(){J.size>10&&J.forEach((function(t,e){O.has(e)||J.delete(e)}));var t=B.map((function(t){return G.get(t.entries[0])})),e=V.length-50;V=V.filter((function(n,r){return r>=e||t.includes(n)}));for(var n=new Set,r=0;r<V.length;r++){var i=V[r];nt(i.startTime,i.processingEnd).forEach((function(t){n.add(t)}))}var a=U.length-1-50;U=U.filter((function(t,e){return t.startTime>_&&e>a||n.has(t)})),K=-1};q.push((function(t){t.interactionId&&t.target&&!J.has(t.interactionId)&&J.set(t.interactionId,t.target)}),(function(t){var e,n=t.startTime+t.duration;_=Math.max(_,t.processingEnd);for(var r=V.length-1;r>=0;r--){var i=V[r];if(Math.abs(n-i.renderTime)<=8){(e=i).startTime=Math.min(t.startTime,e.startTime),e.processingStart=Math.min(t.processingStart,e.processingStart),e.processingEnd=Math.max(t.processingEnd,e.processingEnd),e.entries.push(t);break}}e||(e={startTime:t.startTime,processingStart:t.processingStart,processingEnd:t.processingEnd,renderTime:n,entries:[t]},V.push(e)),(t.interactionId||"first-input"===t.entryType)&&G.set(t,e),X()}));var Z,$,tt,et,nt=function(t,e){for(var n,r=[],i=0;n=U[i];i++)if(!(n.startTime+n.duration<t)){if(n.startTime>e)break;r.push(n)}return r},rt=function(t,n){e||(e=d("long-animation-frame",Q)),z((function(e){var n=function(t){var e=t.entries[0],n=G.get(e),i=e.processingStart,o=n.processingEnd,c=n.entries.sort((function(t,e){return t.processingStart-e.processingStart})),u=nt(e.startTime,o),s=t.entries.find((function(t){return t.target})),f=s&&s.target||J.get(e.interactionId),d=[e.startTime+e.duration,o].concat(u.map((function(t){return t.startTime+t.duration}))),l=Math.max.apply(Math,d),m={interactionTarget:a(f),interactionTargetElement:f,interactionType:e.name.startsWith("key")?"keyboard":"pointer",interactionTime:e.startTime,nextPaintTime:l,processedEventEntries:c,longAnimationFrameEntries:u,inputDelay:i-e.startTime,processingDuration:o-i,presentationDelay:Math.max(l-o,0),loadState:r(e.startTime)};return Object.assign(t,{attribution:m})}(e);t(n)}),n)},it=[2500,4e3],at={},ot=function(t,e){!function(t,e){e=e||{},b((function(){var n,r=S(),i=f("LCP"),a=function(t){e.reportAllChanges||(t=t.slice(-1)),t.forEach((function(t){t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-s(),0),i.entries=[t],n())}))},o=d("largest-contentful-paint",a);if(o){n=l(t,i,it,e.reportAllChanges);var c=v((function(){at[i.id]||(a(o.takeRecords()),o.disconnect(),at[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(t){addEventListener(t,(function(){return N(c)}),{once:!0,capture:!0})})),p(c),u((function(r){i=f("LCP"),n=l(t,i,it,e.reportAllChanges),m((function(){i.value=performance.now()-r.timeStamp,at[i.id]=!0,n(!0)}))}))}}))}((function(e){var r=function(t){var e={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:t.value};if(t.entries.length){var r=n();if(r){var i=r.activationStart||0,o=t.entries[t.entries.length-1],c=o.url&&performance.getEntriesByType("resource").filter((function(t){return t.name===o.url}))[0],u=Math.max(0,r.responseStart-i),s=Math.max(u,c?(c.requestStart||c.startTime)-i:0),f=Math.max(s,c?c.responseEnd-i:0),d=Math.max(f,o.startTime-i);e={element:a(o.element),timeToFirstByte:u,resourceLoadDelay:s-u,resourceLoadDuration:f-s,elementRenderDelay:d-f,navigationEntry:r,lcpEntry:o},o.url&&(e.url=o.url),c&&(e.lcpResourceEntry=c)}}return Object.assign(t,{attribution:e})}(e);t(r)}),e)},ct=[800,1800],ut=function t(e){document.prerendering?b((function(){return t(e)})):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)},st=function(t,e){e=e||{};var r=f("TTFB"),i=l(t,r,ct,e.reportAllChanges);ut((function(){var a=n();a&&(r.value=Math.max(a.responseStart-s(),0),r.entries=[a],i(!0),u((function(){r=f("TTFB",0),(i=l(t,r,ct,e.reportAllChanges))(!0)})))}))},ft=function(t,e){st((function(e){var n=function(t){var e={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(t.entries.length){var n=t.entries[0],r=n.activationStart||0,i=Math.max((n.workerStart||n.fetchStart)-r,0),a=Math.max(n.domainLookupStart-r,0),o=Math.max(n.connectStart-r,0),c=Math.max(n.connectEnd-r,0);e={waitingDuration:i,cacheDuration:a-i,dnsDuration:o-a,connectionDuration:c-o,requestDuration:t.value-c,navigationEntry:n}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},dt={passive:!0,capture:!0},lt=new Date,mt=function(t,e){Z||(Z=e,$=t,tt=new Date,gt(removeEventListener),pt())},pt=function(){if($>=0&&$<tt-lt){var t={entryType:"first-input",name:Z.type,target:Z.target,cancelable:Z.cancelable,startTime:Z.timeStamp,processingStart:Z.timeStamp+$};et.forEach((function(e){e(t)})),et=[]}},vt=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){mt(t,e),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,dt),removeEventListener("pointercancel",r,dt)};addEventListener("pointerup",n,dt),addEventListener("pointercancel",r,dt)}(e,t):mt(e,t)}},gt=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,vt,dt)}))},ht=[100,300],Tt=function(t,e){e=e||{},b((function(){var n,r=S(),i=f("FID"),a=function(t){t.startTime<r.firstHiddenTime&&(i.value=t.processingStart-t.startTime,i.entries.push(t),n(!0))},o=function(t){t.forEach(a)},c=d("first-input",o);n=l(t,i,ht,e.reportAllChanges),c&&(p(v((function(){o(c.takeRecords()),c.disconnect()}))),u((function(){var r;i=f("FID"),n=l(t,i,ht,e.reportAllChanges),et=[],$=-1,Z=null,gt(addEventListener),r=a,et.push(r),pt()})))}))},yt=function(t,e){Tt((function(e){var n=function(t){var e=t.entries[0],n={eventTarget:a(e.target),eventType:e.name,eventTime:e.startTime,eventEntry:e,loadState:r(e.startTime)};return Object.assign(t,{attribution:n})}(e);t(n)}),e)};export{M as CLSThresholds,L as FCPThresholds,ht as FIDThresholds,W as INPThresholds,it as LCPThresholds,ct as TTFBThresholds,D as onCLS,w as onFCP,yt as onFID,rt as onINP,ot as onLCP,ft as onTTFB};
@@ -1 +1 @@
1
- !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).webVitals={})}(this,(function(t){"use strict";var e,n,r,i=function(){var t=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},a=function(t){if("loading"===document.readyState)return"loading";var e=i();if(e){if(t<e.domInteractive)return"loading";if(0===e.domContentLoadedEventStart||t<e.domContentLoadedEventStart)return"dom-interactive";if(0===e.domComplete||t<e.domComplete)return"dom-content-loaded"}return"complete"},o=function(t){var e=t.nodeName;return 1===t.nodeType?e.toLowerCase():e.toUpperCase().replace(/^#/,"")},c=function(t,e){var n="";try{for(;t&&9!==t.nodeType;){var r=t,i=r.id?"#"+r.id:o(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+i.length>(e||100)-1)return n||i;if(n=n?i+">"+n:i,r.id)break;t=r.parentNode}}catch(t){}return n},s=-1,u=function(){return s},f=function(t){addEventListener("pageshow",(function(e){e.persisted&&(s=e.timeStamp,t(e))}),!0)},d=function(){var t=i();return t&&t.activationStart||0},l=function(t,e){var n=i(),r="navigate";u()>=0?r="back-forward-cache":n&&(document.prerendering||d()>0?r="prerender":document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-")));return{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},m=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},p=function(t,e,n,r){var i,a;return function(o){e.value>=0&&(o||r)&&((a=e.value-(i||0))||void 0===i)&&(i=e.value,e.delta=a,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},v=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},h=function(t){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&t()}))},g=function(t){var e=!1;return function(){e||(t(),e=!0)}},T=-1,y=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},E=function(t){"hidden"===document.visibilityState&&T>-1&&(T="visibilitychange"===t.type?t.timeStamp:0,b())},S=function(){addEventListener("visibilitychange",E,!0),addEventListener("prerenderingchange",E,!0)},b=function(){removeEventListener("visibilitychange",E,!0),removeEventListener("prerenderingchange",E,!0)},C=function(){return T<0&&(T=y(),S(),f((function(){setTimeout((function(){T=y(),S()}),0)}))),{get firstHiddenTime(){return T}}},L=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},M=[1800,3e3],D=function(t,e){e=e||{},L((function(){var n,r=C(),i=l("FCP"),a=m("paint",(function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(a.disconnect(),t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-d(),0),i.entries.push(t),n(!0)))}))}));a&&(n=p(t,i,M,e.reportAllChanges),f((function(r){i=l("FCP"),n=p(t,i,M,e.reportAllChanges),v((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))},w=[.1,.25],I=0,x=1/0,F=0,P=function(t){t.forEach((function(t){t.interactionId&&(x=Math.min(x,t.interactionId),F=Math.max(F,t.interactionId),I=F?(F-x)/7+1:0)}))},k=function(){"interactionCount"in performance||e||(e=m("event",P,{type:"event",buffered:!0,durationThreshold:0}))},A=[],B=new Map,O=0,j=function(){return(e?I:performance.interactionCount||0)-O},R=[],q=function(t){if(R.forEach((function(e){return e(t)})),t.interactionId||"first-input"===t.entryType){var e=A[A.length-1],n=B.get(t.interactionId);if(n||A.length<10||t.duration>e.latency){if(n)t.duration>n.latency?(n.entries=[t],n.latency=t.duration):t.duration===n.latency&&t.startTime===n.entries[0].startTime&&n.entries.push(t);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};B.set(r.id,r),A.push(r)}A.sort((function(t,e){return e.latency-t.latency})),A.length>10&&A.splice(10).forEach((function(t){return B.delete(t.id)}))}}},N=function(t){var e=self.requestIdleCallback||self.setTimeout,n=-1;return t=g(t),"hidden"===document.visibilityState?t():(n=e(t),h(t)),n},H=[200,500],V=function(t,e){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(e=e||{},L((function(){var n;k();var r,i=l("INP"),a=function(t){N((function(){t.forEach(q);var e,n=(e=Math.min(A.length-1,Math.floor(j()/50)),A[e]);n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},o=m("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=p(t,i,H,e.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),h((function(){a(o.takeRecords()),r(!0)})),f((function(){O=0,A.length=0,B.clear(),i=l("INP"),r=p(t,i,H,e.reportAllChanges)})))})))},W=[],z=[],U=new WeakMap,_=new Map,G=-1,J=function(t){W=W.concat(t),K()},K=function(){G<0&&(G=N(Q))},Q=function(){_.size>10&&_.forEach((function(t,e){B.has(e)||_.delete(e)}));var t=A.map((function(t){return U.get(t.entries[0])})),e=z.length-50;z=z.filter((function(n,r){return r>=e||t.includes(n)}));for(var n=new Set,i=0;i<z.length;i++){var a=z[i];tt(a.startTime,a.processingEnd).forEach((function(t){n.add(t)}))}for(var o=0;o<50;o++){var c=W[W.length-1-o];if(!c||c.startTime<r)break;n.add(c)}W=Array.from(n),G=-1};R.push((function(t){t.interactionId&&t.target&&!_.has(t.interactionId)&&_.set(t.interactionId,t.target)}),(function(t){var e,n=t.startTime+t.duration;r=Math.max(r,t.processingEnd);for(var i=z.length-1;i>=0;i--){var a=z[i];if(Math.abs(n-a.renderTime)<=8){(e=a).startTime=Math.min(t.startTime,e.startTime),e.processingStart=Math.min(t.processingStart,e.processingStart),e.processingEnd=Math.max(t.processingEnd,e.processingEnd),e.entries.push(t);break}}e||(e={startTime:t.startTime,processingStart:t.processingStart,processingEnd:t.processingEnd,renderTime:n,entries:[t]},z.push(e)),(t.interactionId||"first-input"===t.entryType)&&U.set(t,e),K()}));var X,Y,Z,$,tt=function(t,e){for(var n,r=[],i=0;n=W[i];i++)if(!(n.startTime+n.duration<t)){if(n.startTime>e)break;r.push(n)}return r},et=[2500,4e3],nt={},rt=[800,1800],it=function t(e){document.prerendering?L((function(){return t(e)})):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)},at=function(t,e){e=e||{};var n=l("TTFB"),r=p(t,n,rt,e.reportAllChanges);it((function(){var a=i();a&&(n.value=Math.max(a.responseStart-d(),0),n.entries=[a],r(!0),f((function(){n=l("TTFB",0),(r=p(t,n,rt,e.reportAllChanges))(!0)})))}))},ot={passive:!0,capture:!0},ct=new Date,st=function(t,e){X||(X=e,Y=t,Z=new Date,dt(removeEventListener),ut())},ut=function(){if(Y>=0&&Y<Z-ct){var t={entryType:"first-input",name:X.type,target:X.target,cancelable:X.cancelable,startTime:X.timeStamp,processingStart:X.timeStamp+Y};$.forEach((function(e){e(t)})),$=[]}},ft=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){st(t,e),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,ot),removeEventListener("pointercancel",r,ot)};addEventListener("pointerup",n,ot),addEventListener("pointercancel",r,ot)}(e,t):st(e,t)}},dt=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,ft,ot)}))},lt=[100,300],mt=function(t,e){e=e||{},L((function(){var n,r=C(),i=l("FID"),a=function(t){t.startTime<r.firstHiddenTime&&(i.value=t.processingStart-t.startTime,i.entries.push(t),n(!0))},o=function(t){t.forEach(a)},c=m("first-input",o);n=p(t,i,lt,e.reportAllChanges),c&&(h(g((function(){o(c.takeRecords()),c.disconnect()}))),f((function(){var r;i=l("FID"),n=p(t,i,lt,e.reportAllChanges),$=[],Y=-1,X=null,dt(addEventListener),r=a,$.push(r),ut()})))}))};t.CLSThresholds=w,t.FCPThresholds=M,t.FIDThresholds=lt,t.INPThresholds=H,t.LCPThresholds=et,t.TTFBThresholds=rt,t.onCLS=function(t,e){!function(t,e){e=e||{},D(g((function(){var n,r=l("CLS",0),i=0,a=[],o=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=a[0],n=a[a.length-1];i&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(i+=t.value,a.push(t)):(i=t.value,a=[t])}})),i>r.value&&(r.value=i,r.entries=a,n())},c=m("layout-shift",o);c&&(n=p(t,r,w,e.reportAllChanges),h((function(){o(c.takeRecords()),n(!0)})),f((function(){i=0,r=l("CLS",0),n=p(t,r,w,e.reportAllChanges),v((function(){return n()}))})),setTimeout(n,0))})))}((function(e){var n=function(t){var e,n={};if(t.entries.length){var r=t.entries.reduce((function(t,e){return t&&t.value>e.value?t:e}));if(r&&r.sources&&r.sources.length){var i=(e=r.sources).find((function(t){return t.node&&1===t.node.nodeType}))||e[0];i&&(n={largestShiftTarget:c(i.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:i,largestShiftEntry:r,loadState:a(r.startTime)})}}return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onFCP=function(t,e){D((function(e){var n=function(t){var e={timeToFirstByte:0,firstByteToFCP:t.value,loadState:a(u())};if(t.entries.length){var n=i(),r=t.entries[t.entries.length-1];if(n){var o=n.activationStart||0,c=Math.max(0,n.responseStart-o);e={timeToFirstByte:c,firstByteToFCP:t.value-c,loadState:a(t.entries[0].startTime),navigationEntry:n,fcpEntry:r}}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onFID=function(t,e){mt((function(e){var n=function(t){var e=t.entries[0],n={eventTarget:c(e.target),eventType:e.name,eventTime:e.startTime,eventEntry:e,loadState:a(e.startTime)};return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onINP=function(t,e){n||(n=m("long-animation-frame",J)),V((function(e){var n=function(t){var e=t.entries[0],n=U.get(e),r=e.processingStart,i=n.processingEnd,o=n.entries.sort((function(t,e){return t.processingStart-e.processingStart})),s=tt(e.startTime,i),u=t.entries.find((function(t){return t.target})),f=u&&u.target||_.get(e.interactionId),d=[e.startTime+e.duration,i].concat(s.map((function(t){return t.startTime+t.duration}))),l=Math.max.apply(Math,d),m={interactionTarget:c(f),interactionTargetElement:f,interactionType:e.name.startsWith("key")?"keyboard":"pointer",interactionTime:e.startTime,nextPaintTime:l,processedEventEntries:o,longAnimationFrameEntries:s,inputDelay:r-e.startTime,processingDuration:i-r,presentationDelay:Math.max(l-i,0),loadState:a(e.startTime)};return Object.assign(t,{attribution:m})}(e);t(n)}),e)},t.onLCP=function(t,e){!function(t,e){e=e||{},L((function(){var n,r=C(),i=l("LCP"),a=function(t){e.reportAllChanges||(t=t.slice(-1)),t.forEach((function(t){t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-d(),0),i.entries=[t],n())}))},o=m("largest-contentful-paint",a);if(o){n=p(t,i,et,e.reportAllChanges);var c=g((function(){nt[i.id]||(a(o.takeRecords()),o.disconnect(),nt[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(t){addEventListener(t,(function(){return N(c)}),!0)})),h(c),f((function(r){i=l("LCP"),n=p(t,i,et,e.reportAllChanges),v((function(){i.value=performance.now()-r.timeStamp,nt[i.id]=!0,n(!0)}))}))}}))}((function(e){var n=function(t){var e={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:t.value};if(t.entries.length){var n=i();if(n){var r=n.activationStart||0,a=t.entries[t.entries.length-1],o=a.url&&performance.getEntriesByType("resource").filter((function(t){return t.name===a.url}))[0],s=Math.max(0,n.responseStart-r),u=Math.max(s,o?(o.requestStart||o.startTime)-r:0),f=Math.max(u,o?o.responseEnd-r:0),d=Math.max(f,a.startTime-r);e={element:c(a.element),timeToFirstByte:s,resourceLoadDelay:u-s,resourceLoadDuration:f-u,elementRenderDelay:d-f,navigationEntry:n,lcpEntry:a},a.url&&(e.url=a.url),o&&(e.lcpResourceEntry=o)}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onTTFB=function(t,e){at((function(e){var n=function(t){var e={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(t.entries.length){var n=t.entries[0],r=n.activationStart||0,i=Math.max((n.workerStart||n.fetchStart)-r,0),a=Math.max(n.domainLookupStart-r,0),o=Math.max(n.connectStart-r,0),c=Math.max(n.connectEnd-r,0);e={waitingDuration:i,cacheDuration:a-i,dnsDuration:o-a,connectionDuration:c-o,requestDuration:t.value-c,navigationEntry:n}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)}}));
1
+ !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).webVitals={})}(this,(function(t){"use strict";var e,n,r=function(){var t=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},i=function(t){if("loading"===document.readyState)return"loading";var e=r();if(e){if(t<e.domInteractive)return"loading";if(0===e.domContentLoadedEventStart||t<e.domContentLoadedEventStart)return"dom-interactive";if(0===e.domComplete||t<e.domComplete)return"dom-content-loaded"}return"complete"},a=function(t){var e=t.nodeName;return 1===t.nodeType?e.toLowerCase():e.toUpperCase().replace(/^#/,"")},o=function(t,e){var n="";try{for(;t&&9!==t.nodeType;){var r=t,i=r.id?"#"+r.id:a(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+i.length>(e||100)-1)return n||i;if(n=n?i+">"+n:i,r.id)break;t=r.parentNode}}catch(t){}return n},c=-1,s=function(){return c},u=function(t){addEventListener("pageshow",(function(e){e.persisted&&(c=e.timeStamp,t(e))}),!0)},f=function(){var t=r();return t&&t.activationStart||0},d=function(t,e){var n=r(),i="navigate";s()>=0?i="back-forward-cache":n&&(document.prerendering||f()>0?i="prerender":document.wasDiscarded?i="restore":n.type&&(i=n.type.replace(/_/g,"-")));return{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:i}},l=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},m=function(t,e,n,r){var i,a;return function(o){e.value>=0&&(o||r)&&((a=e.value-(i||0))||void 0===i)&&(i=e.value,e.delta=a,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},p=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},v=function(t){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&t()}))},h=function(t){var e=!1;return function(){e||(t(),e=!0)}},g=-1,T=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},y=function(t){"hidden"===document.visibilityState&&g>-1&&(g="visibilitychange"===t.type?t.timeStamp:0,S())},E=function(){addEventListener("visibilitychange",y,!0),addEventListener("prerenderingchange",y,!0)},S=function(){removeEventListener("visibilitychange",y,!0),removeEventListener("prerenderingchange",y,!0)},b=function(){return g<0&&(g=T(),E(),u((function(){setTimeout((function(){g=T(),E()}),0)}))),{get firstHiddenTime(){return g}}},C=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},L=[1800,3e3],M=function(t,e){e=e||{},C((function(){var n,r=b(),i=d("FCP"),a=l("paint",(function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(a.disconnect(),t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-f(),0),i.entries.push(t),n(!0)))}))}));a&&(n=m(t,i,L,e.reportAllChanges),u((function(r){i=d("FCP"),n=m(t,i,L,e.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))},D=[.1,.25],w=0,I=1/0,x=0,F=function(t){t.forEach((function(t){t.interactionId&&(I=Math.min(I,t.interactionId),x=Math.max(x,t.interactionId),w=x?(x-I)/7+1:0)}))},P=function(){return e?w:performance.interactionCount||0},k=function(){"interactionCount"in performance||e||(e=l("event",F,{type:"event",buffered:!0,durationThreshold:0}))},A=[],B=new Map,O=0,j=function(){var t=Math.min(A.length-1,Math.floor((P()-O)/50));return A[t]},R=[],q=function(t){if(R.forEach((function(e){return e(t)})),t.interactionId||"first-input"===t.entryType){var e=A[A.length-1],n=B.get(t.interactionId);if(n||A.length<10||t.duration>e.latency){if(n)t.duration>n.latency?(n.entries=[t],n.latency=t.duration):t.duration===n.latency&&t.startTime===n.entries[0].startTime&&n.entries.push(t);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};B.set(r.id,r),A.push(r)}A.sort((function(t,e){return e.latency-t.latency})),A.length>10&&A.splice(10).forEach((function(t){return B.delete(t.id)}))}}},N=function(t){var e=self.requestIdleCallback||self.setTimeout,n=-1;return t=h(t),"hidden"===document.visibilityState?t():(n=e(t),v(t)),n},H=[200,500],V=function(t,e){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(e=e||{},C((function(){var n;k();var r,i=d("INP"),a=function(t){N((function(){t.forEach(q);var e=j();e&&e.latency!==i.value&&(i.value=e.latency,i.entries=e.entries,r())}))},o=l("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=m(t,i,H,e.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),v((function(){a(o.takeRecords()),r(!0)})),u((function(){O=P(),A.length=0,B.clear(),i=d("INP"),r=m(t,i,H,e.reportAllChanges)})))})))},W=[],z=[],U=0,_=new WeakMap,G=new Map,J=-1,K=function(t){W=W.concat(t),Q()},Q=function(){J<0&&(J=N(X))},X=function(){G.size>10&&G.forEach((function(t,e){B.has(e)||G.delete(e)}));var t=A.map((function(t){return _.get(t.entries[0])})),e=z.length-50;z=z.filter((function(n,r){return r>=e||t.includes(n)}));for(var n=new Set,r=0;r<z.length;r++){var i=z[r];et(i.startTime,i.processingEnd).forEach((function(t){n.add(t)}))}var a=W.length-1-50;W=W.filter((function(t,e){return t.startTime>U&&e>a||n.has(t)})),J=-1};R.push((function(t){t.interactionId&&t.target&&!G.has(t.interactionId)&&G.set(t.interactionId,t.target)}),(function(t){var e,n=t.startTime+t.duration;U=Math.max(U,t.processingEnd);for(var r=z.length-1;r>=0;r--){var i=z[r];if(Math.abs(n-i.renderTime)<=8){(e=i).startTime=Math.min(t.startTime,e.startTime),e.processingStart=Math.min(t.processingStart,e.processingStart),e.processingEnd=Math.max(t.processingEnd,e.processingEnd),e.entries.push(t);break}}e||(e={startTime:t.startTime,processingStart:t.processingStart,processingEnd:t.processingEnd,renderTime:n,entries:[t]},z.push(e)),(t.interactionId||"first-input"===t.entryType)&&_.set(t,e),Q()}));var Y,Z,$,tt,et=function(t,e){for(var n,r=[],i=0;n=W[i];i++)if(!(n.startTime+n.duration<t)){if(n.startTime>e)break;r.push(n)}return r},nt=[2500,4e3],rt={},it=[800,1800],at=function t(e){document.prerendering?C((function(){return t(e)})):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)},ot=function(t,e){e=e||{};var n=d("TTFB"),i=m(t,n,it,e.reportAllChanges);at((function(){var a=r();a&&(n.value=Math.max(a.responseStart-f(),0),n.entries=[a],i(!0),u((function(){n=d("TTFB",0),(i=m(t,n,it,e.reportAllChanges))(!0)})))}))},ct={passive:!0,capture:!0},st=new Date,ut=function(t,e){Y||(Y=e,Z=t,$=new Date,lt(removeEventListener),ft())},ft=function(){if(Z>=0&&Z<$-st){var t={entryType:"first-input",name:Y.type,target:Y.target,cancelable:Y.cancelable,startTime:Y.timeStamp,processingStart:Y.timeStamp+Z};tt.forEach((function(e){e(t)})),tt=[]}},dt=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){ut(t,e),i()},r=function(){i()},i=function(){removeEventListener("pointerup",n,ct),removeEventListener("pointercancel",r,ct)};addEventListener("pointerup",n,ct),addEventListener("pointercancel",r,ct)}(e,t):ut(e,t)}},lt=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,dt,ct)}))},mt=[100,300],pt=function(t,e){e=e||{},C((function(){var n,r=b(),i=d("FID"),a=function(t){t.startTime<r.firstHiddenTime&&(i.value=t.processingStart-t.startTime,i.entries.push(t),n(!0))},o=function(t){t.forEach(a)},c=l("first-input",o);n=m(t,i,mt,e.reportAllChanges),c&&(v(h((function(){o(c.takeRecords()),c.disconnect()}))),u((function(){var r;i=d("FID"),n=m(t,i,mt,e.reportAllChanges),tt=[],Z=-1,Y=null,lt(addEventListener),r=a,tt.push(r),ft()})))}))};t.CLSThresholds=D,t.FCPThresholds=L,t.FIDThresholds=mt,t.INPThresholds=H,t.LCPThresholds=nt,t.TTFBThresholds=it,t.onCLS=function(t,e){!function(t,e){e=e||{},M(h((function(){var n,r=d("CLS",0),i=0,a=[],o=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=a[0],n=a[a.length-1];i&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(i+=t.value,a.push(t)):(i=t.value,a=[t])}})),i>r.value&&(r.value=i,r.entries=a,n())},c=l("layout-shift",o);c&&(n=m(t,r,D,e.reportAllChanges),v((function(){o(c.takeRecords()),n(!0)})),u((function(){i=0,r=d("CLS",0),n=m(t,r,D,e.reportAllChanges),p((function(){return n()}))})),setTimeout(n,0))})))}((function(e){var n=function(t){var e,n={};if(t.entries.length){var r=t.entries.reduce((function(t,e){return t&&t.value>e.value?t:e}));if(r&&r.sources&&r.sources.length){var a=(e=r.sources).find((function(t){return t.node&&1===t.node.nodeType}))||e[0];a&&(n={largestShiftTarget:o(a.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:a,largestShiftEntry:r,loadState:i(r.startTime)})}}return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onFCP=function(t,e){M((function(e){var n=function(t){var e={timeToFirstByte:0,firstByteToFCP:t.value,loadState:i(s())};if(t.entries.length){var n=r(),a=t.entries[t.entries.length-1];if(n){var o=n.activationStart||0,c=Math.max(0,n.responseStart-o);e={timeToFirstByte:c,firstByteToFCP:t.value-c,loadState:i(t.entries[0].startTime),navigationEntry:n,fcpEntry:a}}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onFID=function(t,e){pt((function(e){var n=function(t){var e=t.entries[0],n={eventTarget:o(e.target),eventType:e.name,eventTime:e.startTime,eventEntry:e,loadState:i(e.startTime)};return Object.assign(t,{attribution:n})}(e);t(n)}),e)},t.onINP=function(t,e){n||(n=l("long-animation-frame",K)),V((function(e){var n=function(t){var e=t.entries[0],n=_.get(e),r=e.processingStart,a=n.processingEnd,c=n.entries.sort((function(t,e){return t.processingStart-e.processingStart})),s=et(e.startTime,a),u=t.entries.find((function(t){return t.target})),f=u&&u.target||G.get(e.interactionId),d=[e.startTime+e.duration,a].concat(s.map((function(t){return t.startTime+t.duration}))),l=Math.max.apply(Math,d),m={interactionTarget:o(f),interactionTargetElement:f,interactionType:e.name.startsWith("key")?"keyboard":"pointer",interactionTime:e.startTime,nextPaintTime:l,processedEventEntries:c,longAnimationFrameEntries:s,inputDelay:r-e.startTime,processingDuration:a-r,presentationDelay:Math.max(l-a,0),loadState:i(e.startTime)};return Object.assign(t,{attribution:m})}(e);t(n)}),e)},t.onLCP=function(t,e){!function(t,e){e=e||{},C((function(){var n,r=b(),i=d("LCP"),a=function(t){e.reportAllChanges||(t=t.slice(-1)),t.forEach((function(t){t.startTime<r.firstHiddenTime&&(i.value=Math.max(t.startTime-f(),0),i.entries=[t],n())}))},o=l("largest-contentful-paint",a);if(o){n=m(t,i,nt,e.reportAllChanges);var c=h((function(){rt[i.id]||(a(o.takeRecords()),o.disconnect(),rt[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(t){addEventListener(t,(function(){return N(c)}),{once:!0,capture:!0})})),v(c),u((function(r){i=d("LCP"),n=m(t,i,nt,e.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,rt[i.id]=!0,n(!0)}))}))}}))}((function(e){var n=function(t){var e={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:t.value};if(t.entries.length){var n=r();if(n){var i=n.activationStart||0,a=t.entries[t.entries.length-1],c=a.url&&performance.getEntriesByType("resource").filter((function(t){return t.name===a.url}))[0],s=Math.max(0,n.responseStart-i),u=Math.max(s,c?(c.requestStart||c.startTime)-i:0),f=Math.max(u,c?c.responseEnd-i:0),d=Math.max(f,a.startTime-i);e={element:o(a.element),timeToFirstByte:s,resourceLoadDelay:u-s,resourceLoadDuration:f-u,elementRenderDelay:d-f,navigationEntry:n,lcpEntry:a},a.url&&(e.url=a.url),c&&(e.lcpResourceEntry=c)}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)},t.onTTFB=function(t,e){ot((function(e){var n=function(t){var e={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(t.entries.length){var n=t.entries[0],r=n.activationStart||0,i=Math.max((n.workerStart||n.fetchStart)-r,0),a=Math.max(n.domainLookupStart-r,0),o=Math.max(n.connectStart-r,0),c=Math.max(n.connectEnd-r,0);e={waitingDuration:i,cacheDuration:a-i,dnsDuration:o-a,connectionDuration:c-o,requestDuration:t.value-c,navigationEntry:n}}return Object.assign(t,{attribution:e})}(e);t(n)}),e)}}));
@@ -1 +1 @@
1
- var webVitals=function(e){"use strict";var n,t,r,i,o,a=-1,c=function(e){addEventListener("pageshow",(function(n){n.persisted&&(a=n.timeStamp,e(n))}),!0)},u=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},s=function(){var e=u();return e&&e.activationStart||0},f=function(e,n){var t=u(),r="navigate";a>=0?r="back-forward-cache":t&&(document.prerendering||s()>0?r="prerender":document.wasDiscarded?r="restore":t.type&&(r=t.type.replace(/_/g,"-")));return{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},d=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},t||{})),r}}catch(e){}},l=function(e,n,t,r){var i,o;return function(a){n.value>=0&&(a||r)&&((o=n.value-(i||0))||void 0===i)&&(i=n.value,n.delta=o,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},p=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},v=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},m=function(e){var n=!1;return function(){n||(e(),n=!0)}},h=-1,g=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},T=function(e){"hidden"===document.visibilityState&&h>-1&&(h="visibilitychange"===e.type?e.timeStamp:0,E())},y=function(){addEventListener("visibilitychange",T,!0),addEventListener("prerenderingchange",T,!0)},E=function(){removeEventListener("visibilitychange",T,!0),removeEventListener("prerenderingchange",T,!0)},C=function(){return h<0&&(h=g(),y(),c((function(){setTimeout((function(){h=g(),y()}),0)}))),{get firstHiddenTime(){return h}}},L=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},S=[1800,3e3],b=function(e,n){n=n||{},L((function(){var t,r=C(),i=f("FCP"),o=d("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(o.disconnect(),e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-s(),0),i.entries.push(e),t(!0)))}))}));o&&(t=l(e,i,S,n.reportAllChanges),c((function(r){i=f("FCP"),t=l(e,i,S,n.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,t(!0)}))})))}))},w=[.1,.25],I=0,P=1/0,A=0,F=function(e){e.forEach((function(e){e.interactionId&&(P=Math.min(P,e.interactionId),A=Math.max(A,e.interactionId),I=A?(A-P)/7+1:0)}))},M=function(){"interactionCount"in performance||n||(n=d("event",F,{type:"event",buffered:!0,durationThreshold:0}))},k=[],D=new Map,B=0,R=function(){return(n?I:performance.interactionCount||0)-B},x=[],H=function(e){if(x.forEach((function(n){return n(e)})),e.interactionId||"first-input"===e.entryType){var n=k[k.length-1],t=D.get(e.interactionId);if(t||k.length<10||e.duration>n.latency){if(t)e.duration>t.latency?(t.entries=[e],t.latency=e.duration):e.duration===t.latency&&e.startTime===t.entries[0].startTime&&t.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};D.set(r.id,r),k.push(r)}k.sort((function(e,n){return n.latency-e.latency})),k.length>10&&k.splice(10).forEach((function(e){return D.delete(e.id)}))}}},N=function(e){var n=self.requestIdleCallback||self.setTimeout,t=-1;return e=m(e),"hidden"===document.visibilityState?e():(t=n(e),v(e)),t},q=[200,500],O=[2500,4e3],j={},V=[800,1800],_=function e(n){document.prerendering?L((function(){return e(n)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(n)}),!0):setTimeout(n,0)},z={passive:!0,capture:!0},G=new Date,J=function(e,n){t||(t=n,r=e,i=new Date,U(removeEventListener),K())},K=function(){if(r>=0&&r<i-G){var e={entryType:"first-input",name:t.type,target:t.target,cancelable:t.cancelable,startTime:t.timeStamp,processingStart:t.timeStamp+r};o.forEach((function(n){n(e)})),o=[]}},Q=function(e){if(e.cancelable){var n=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){J(e,n),i()},r=function(){i()},i=function(){removeEventListener("pointerup",t,z),removeEventListener("pointercancel",r,z)};addEventListener("pointerup",t,z),addEventListener("pointercancel",r,z)}(n,e):J(n,e)}},U=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,Q,z)}))},W=[100,300];return e.CLSThresholds=w,e.FCPThresholds=S,e.FIDThresholds=W,e.INPThresholds=q,e.LCPThresholds=O,e.TTFBThresholds=V,e.onCLS=function(e,n){n=n||{},b(m((function(){var t,r=f("CLS",0),i=0,o=[],a=function(e){e.forEach((function(e){if(!e.hadRecentInput){var n=o[0],t=o[o.length-1];i&&e.startTime-t.startTime<1e3&&e.startTime-n.startTime<5e3?(i+=e.value,o.push(e)):(i=e.value,o=[e])}})),i>r.value&&(r.value=i,r.entries=o,t())},u=d("layout-shift",a);u&&(t=l(e,r,w,n.reportAllChanges),v((function(){a(u.takeRecords()),t(!0)})),c((function(){i=0,r=f("CLS",0),t=l(e,r,w,n.reportAllChanges),p((function(){return t()}))})),setTimeout(t,0))})))},e.onFCP=b,e.onFID=function(e,n){n=n||{},L((function(){var i,a=C(),u=f("FID"),s=function(e){e.startTime<a.firstHiddenTime&&(u.value=e.processingStart-e.startTime,u.entries.push(e),i(!0))},p=function(e){e.forEach(s)},h=d("first-input",p);i=l(e,u,W,n.reportAllChanges),h&&(v(m((function(){p(h.takeRecords()),h.disconnect()}))),c((function(){var a;u=f("FID"),i=l(e,u,W,n.reportAllChanges),o=[],r=-1,t=null,U(addEventListener),a=s,o.push(a),K()})))}))},e.onINP=function(e,n){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(n=n||{},L((function(){var t;M();var r,i=f("INP"),o=function(e){N((function(){e.forEach(H);var n,t=(n=Math.min(k.length-1,Math.floor(R()/50)),k[n]);t&&t.latency!==i.value&&(i.value=t.latency,i.entries=t.entries,r())}))},a=d("event",o,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});r=l(e,i,q,n.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),v((function(){o(a.takeRecords()),r(!0)})),c((function(){B=0,k.length=0,D.clear(),i=f("INP"),r=l(e,i,q,n.reportAllChanges)})))})))},e.onLCP=function(e,n){n=n||{},L((function(){var t,r=C(),i=f("LCP"),o=function(e){n.reportAllChanges||(e=e.slice(-1)),e.forEach((function(e){e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-s(),0),i.entries=[e],t())}))},a=d("largest-contentful-paint",o);if(a){t=l(e,i,O,n.reportAllChanges);var u=m((function(){j[i.id]||(o(a.takeRecords()),a.disconnect(),j[i.id]=!0,t(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return N(u)}),!0)})),v(u),c((function(r){i=f("LCP"),t=l(e,i,O,n.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,j[i.id]=!0,t(!0)}))}))}}))},e.onTTFB=function(e,n){n=n||{};var t=f("TTFB"),r=l(e,t,V,n.reportAllChanges);_((function(){var i=u();i&&(t.value=Math.max(i.responseStart-s(),0),t.entries=[i],r(!0),c((function(){t=f("TTFB",0),(r=l(e,t,V,n.reportAllChanges))(!0)})))}))},e}({});
1
+ var webVitals=function(e){"use strict";var n,t,r,i,o,a=-1,c=function(e){addEventListener("pageshow",(function(n){n.persisted&&(a=n.timeStamp,e(n))}),!0)},u=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},s=function(){var e=u();return e&&e.activationStart||0},f=function(e,n){var t=u(),r="navigate";a>=0?r="back-forward-cache":t&&(document.prerendering||s()>0?r="prerender":document.wasDiscarded?r="restore":t.type&&(r=t.type.replace(/_/g,"-")));return{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},d=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},t||{})),r}}catch(e){}},l=function(e,n,t,r){var i,o;return function(a){n.value>=0&&(a||r)&&((o=n.value-(i||0))||void 0===i)&&(i=n.value,n.delta=o,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},p=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},v=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},m=function(e){var n=!1;return function(){n||(e(),n=!0)}},h=-1,g=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},T=function(e){"hidden"===document.visibilityState&&h>-1&&(h="visibilitychange"===e.type?e.timeStamp:0,E())},y=function(){addEventListener("visibilitychange",T,!0),addEventListener("prerenderingchange",T,!0)},E=function(){removeEventListener("visibilitychange",T,!0),removeEventListener("prerenderingchange",T,!0)},C=function(){return h<0&&(h=g(),y(),c((function(){setTimeout((function(){h=g(),y()}),0)}))),{get firstHiddenTime(){return h}}},L=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},S=[1800,3e3],b=function(e,n){n=n||{},L((function(){var t,r=C(),i=f("FCP"),o=d("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(o.disconnect(),e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-s(),0),i.entries.push(e),t(!0)))}))}));o&&(t=l(e,i,S,n.reportAllChanges),c((function(r){i=f("FCP"),t=l(e,i,S,n.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,t(!0)}))})))}))},w=[.1,.25],I=0,P=1/0,A=0,F=function(e){e.forEach((function(e){e.interactionId&&(P=Math.min(P,e.interactionId),A=Math.max(A,e.interactionId),I=A?(A-P)/7+1:0)}))},M=function(){return n?I:performance.interactionCount||0},k=function(){"interactionCount"in performance||n||(n=d("event",F,{type:"event",buffered:!0,durationThreshold:0}))},D=[],B=new Map,R=0,x=function(){var e=Math.min(D.length-1,Math.floor((M()-R)/50));return D[e]},H=[],N=function(e){if(H.forEach((function(n){return n(e)})),e.interactionId||"first-input"===e.entryType){var n=D[D.length-1],t=B.get(e.interactionId);if(t||D.length<10||e.duration>n.latency){if(t)e.duration>t.latency?(t.entries=[e],t.latency=e.duration):e.duration===t.latency&&e.startTime===t.entries[0].startTime&&t.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};B.set(r.id,r),D.push(r)}D.sort((function(e,n){return n.latency-e.latency})),D.length>10&&D.splice(10).forEach((function(e){return B.delete(e.id)}))}}},q=function(e){var n=self.requestIdleCallback||self.setTimeout,t=-1;return e=m(e),"hidden"===document.visibilityState?e():(t=n(e),v(e)),t},O=[200,500],j=[2500,4e3],V={},_=[800,1800],z=function e(n){document.prerendering?L((function(){return e(n)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(n)}),!0):setTimeout(n,0)},G={passive:!0,capture:!0},J=new Date,K=function(e,n){t||(t=n,r=e,i=new Date,W(removeEventListener),Q())},Q=function(){if(r>=0&&r<i-J){var e={entryType:"first-input",name:t.type,target:t.target,cancelable:t.cancelable,startTime:t.timeStamp,processingStart:t.timeStamp+r};o.forEach((function(n){n(e)})),o=[]}},U=function(e){if(e.cancelable){var n=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){K(e,n),i()},r=function(){i()},i=function(){removeEventListener("pointerup",t,G),removeEventListener("pointercancel",r,G)};addEventListener("pointerup",t,G),addEventListener("pointercancel",r,G)}(n,e):K(n,e)}},W=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,U,G)}))},X=[100,300];return e.CLSThresholds=w,e.FCPThresholds=S,e.FIDThresholds=X,e.INPThresholds=O,e.LCPThresholds=j,e.TTFBThresholds=_,e.onCLS=function(e,n){n=n||{},b(m((function(){var t,r=f("CLS",0),i=0,o=[],a=function(e){e.forEach((function(e){if(!e.hadRecentInput){var n=o[0],t=o[o.length-1];i&&e.startTime-t.startTime<1e3&&e.startTime-n.startTime<5e3?(i+=e.value,o.push(e)):(i=e.value,o=[e])}})),i>r.value&&(r.value=i,r.entries=o,t())},u=d("layout-shift",a);u&&(t=l(e,r,w,n.reportAllChanges),v((function(){a(u.takeRecords()),t(!0)})),c((function(){i=0,r=f("CLS",0),t=l(e,r,w,n.reportAllChanges),p((function(){return t()}))})),setTimeout(t,0))})))},e.onFCP=b,e.onFID=function(e,n){n=n||{},L((function(){var i,a=C(),u=f("FID"),s=function(e){e.startTime<a.firstHiddenTime&&(u.value=e.processingStart-e.startTime,u.entries.push(e),i(!0))},p=function(e){e.forEach(s)},h=d("first-input",p);i=l(e,u,X,n.reportAllChanges),h&&(v(m((function(){p(h.takeRecords()),h.disconnect()}))),c((function(){var a;u=f("FID"),i=l(e,u,X,n.reportAllChanges),o=[],r=-1,t=null,W(addEventListener),a=s,o.push(a),Q()})))}))},e.onINP=function(e,n){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(n=n||{},L((function(){var t;k();var r,i=f("INP"),o=function(e){q((function(){e.forEach(N);var n=x();n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},a=d("event",o,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});r=l(e,i,O,n.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),v((function(){o(a.takeRecords()),r(!0)})),c((function(){R=M(),D.length=0,B.clear(),i=f("INP"),r=l(e,i,O,n.reportAllChanges)})))})))},e.onLCP=function(e,n){n=n||{},L((function(){var t,r=C(),i=f("LCP"),o=function(e){n.reportAllChanges||(e=e.slice(-1)),e.forEach((function(e){e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-s(),0),i.entries=[e],t())}))},a=d("largest-contentful-paint",o);if(a){t=l(e,i,j,n.reportAllChanges);var u=m((function(){V[i.id]||(o(a.takeRecords()),a.disconnect(),V[i.id]=!0,t(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return q(u)}),{once:!0,capture:!0})})),v(u),c((function(r){i=f("LCP"),t=l(e,i,j,n.reportAllChanges),p((function(){i.value=performance.now()-r.timeStamp,V[i.id]=!0,t(!0)}))}))}}))},e.onTTFB=function(e,n){n=n||{};var t=f("TTFB"),r=l(e,t,_,n.reportAllChanges);z((function(){var i=u();i&&(t.value=Math.max(i.responseStart-s(),0),t.entries=[i],r(!0),c((function(){t=f("TTFB",0),(r=l(e,t,_,n.reportAllChanges))(!0)})))}))},e}({});
@@ -1 +1 @@
1
- var e,n,t,r,i,o=-1,a=function(e){addEventListener("pageshow",(function(n){n.persisted&&(o=n.timeStamp,e(n))}),!0)},c=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},u=function(){var e=c();return e&&e.activationStart||0},f=function(e,n){var t=c(),r="navigate";o>=0?r="back-forward-cache":t&&(document.prerendering||u()>0?r="prerender":document.wasDiscarded?r="restore":t.type&&(r=t.type.replace(/_/g,"-")));return{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},s=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},t||{})),r}}catch(e){}},d=function(e,n,t,r){var i,o;return function(a){n.value>=0&&(a||r)&&((o=n.value-(i||0))||void 0===i)&&(i=n.value,n.delta=o,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},l=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},p=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},v=function(e){var n=!1;return function(){n||(e(),n=!0)}},m=-1,h=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},g=function(e){"hidden"===document.visibilityState&&m>-1&&(m="visibilitychange"===e.type?e.timeStamp:0,T())},y=function(){addEventListener("visibilitychange",g,!0),addEventListener("prerenderingchange",g,!0)},T=function(){removeEventListener("visibilitychange",g,!0),removeEventListener("prerenderingchange",g,!0)},E=function(){return m<0&&(m=h(),y(),a((function(){setTimeout((function(){m=h(),y()}),0)}))),{get firstHiddenTime(){return m}}},C=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},b=[1800,3e3],S=function(e,n){n=n||{},C((function(){var t,r=E(),i=f("FCP"),o=s("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(o.disconnect(),e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-u(),0),i.entries.push(e),t(!0)))}))}));o&&(t=d(e,i,b,n.reportAllChanges),a((function(r){i=f("FCP"),t=d(e,i,b,n.reportAllChanges),l((function(){i.value=performance.now()-r.timeStamp,t(!0)}))})))}))},L=[.1,.25],w=function(e,n){n=n||{},S(v((function(){var t,r=f("CLS",0),i=0,o=[],c=function(e){e.forEach((function(e){if(!e.hadRecentInput){var n=o[0],t=o[o.length-1];i&&e.startTime-t.startTime<1e3&&e.startTime-n.startTime<5e3?(i+=e.value,o.push(e)):(i=e.value,o=[e])}})),i>r.value&&(r.value=i,r.entries=o,t())},u=s("layout-shift",c);u&&(t=d(e,r,L,n.reportAllChanges),p((function(){c(u.takeRecords()),t(!0)})),a((function(){i=0,r=f("CLS",0),t=d(e,r,L,n.reportAllChanges),l((function(){return t()}))})),setTimeout(t,0))})))},A=0,I=1/0,P=0,M=function(e){e.forEach((function(e){e.interactionId&&(I=Math.min(I,e.interactionId),P=Math.max(P,e.interactionId),A=P?(P-I)/7+1:0)}))},k=function(){"interactionCount"in performance||e||(e=s("event",M,{type:"event",buffered:!0,durationThreshold:0}))},F=[],D=new Map,x=0,R=function(){return(e?A:performance.interactionCount||0)-x},B=[],H=function(e){if(B.forEach((function(n){return n(e)})),e.interactionId||"first-input"===e.entryType){var n=F[F.length-1],t=D.get(e.interactionId);if(t||F.length<10||e.duration>n.latency){if(t)e.duration>t.latency?(t.entries=[e],t.latency=e.duration):e.duration===t.latency&&e.startTime===t.entries[0].startTime&&t.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};D.set(r.id,r),F.push(r)}F.sort((function(e,n){return n.latency-e.latency})),F.length>10&&F.splice(10).forEach((function(e){return D.delete(e.id)}))}}},q=function(e){var n=self.requestIdleCallback||self.setTimeout,t=-1;return e=v(e),"hidden"===document.visibilityState?e():(t=n(e),p(e)),t},O=[200,500],N=function(e,n){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(n=n||{},C((function(){var t;k();var r,i=f("INP"),o=function(e){q((function(){e.forEach(H);var n,t=(n=Math.min(F.length-1,Math.floor(R()/50)),F[n]);t&&t.latency!==i.value&&(i.value=t.latency,i.entries=t.entries,r())}))},c=s("event",o,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});r=d(e,i,O,n.reportAllChanges),c&&(c.observe({type:"first-input",buffered:!0}),p((function(){o(c.takeRecords()),r(!0)})),a((function(){x=0,F.length=0,D.clear(),i=f("INP"),r=d(e,i,O,n.reportAllChanges)})))})))},j=[2500,4e3],_={},z=function(e,n){n=n||{},C((function(){var t,r=E(),i=f("LCP"),o=function(e){n.reportAllChanges||(e=e.slice(-1)),e.forEach((function(e){e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-u(),0),i.entries=[e],t())}))},c=s("largest-contentful-paint",o);if(c){t=d(e,i,j,n.reportAllChanges);var m=v((function(){_[i.id]||(o(c.takeRecords()),c.disconnect(),_[i.id]=!0,t(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return q(m)}),!0)})),p(m),a((function(r){i=f("LCP"),t=d(e,i,j,n.reportAllChanges),l((function(){i.value=performance.now()-r.timeStamp,_[i.id]=!0,t(!0)}))}))}}))},G=[800,1800],J=function e(n){document.prerendering?C((function(){return e(n)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(n)}),!0):setTimeout(n,0)},K=function(e,n){n=n||{};var t=f("TTFB"),r=d(e,t,G,n.reportAllChanges);J((function(){var i=c();i&&(t.value=Math.max(i.responseStart-u(),0),t.entries=[i],r(!0),a((function(){t=f("TTFB",0),(r=d(e,t,G,n.reportAllChanges))(!0)})))}))},Q={passive:!0,capture:!0},U=new Date,V=function(e,i){n||(n=i,t=e,r=new Date,Y(removeEventListener),W())},W=function(){if(t>=0&&t<r-U){var e={entryType:"first-input",name:n.type,target:n.target,cancelable:n.cancelable,startTime:n.timeStamp,processingStart:n.timeStamp+t};i.forEach((function(n){n(e)})),i=[]}},X=function(e){if(e.cancelable){var n=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){V(e,n),i()},r=function(){i()},i=function(){removeEventListener("pointerup",t,Q),removeEventListener("pointercancel",r,Q)};addEventListener("pointerup",t,Q),addEventListener("pointercancel",r,Q)}(n,e):V(n,e)}},Y=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,X,Q)}))},Z=[100,300],$=function(e,r){r=r||{},C((function(){var o,c=E(),u=f("FID"),l=function(e){e.startTime<c.firstHiddenTime&&(u.value=e.processingStart-e.startTime,u.entries.push(e),o(!0))},m=function(e){e.forEach(l)},h=s("first-input",m);o=d(e,u,Z,r.reportAllChanges),h&&(p(v((function(){m(h.takeRecords()),h.disconnect()}))),a((function(){var a;u=f("FID"),o=d(e,u,Z,r.reportAllChanges),i=[],t=-1,n=null,Y(addEventListener),a=l,i.push(a),W()})))}))};export{L as CLSThresholds,b as FCPThresholds,Z as FIDThresholds,O as INPThresholds,j as LCPThresholds,G as TTFBThresholds,w as onCLS,S as onFCP,$ as onFID,N as onINP,z as onLCP,K as onTTFB};
1
+ var e,n,t,r,i,o=-1,a=function(e){addEventListener("pageshow",(function(n){n.persisted&&(o=n.timeStamp,e(n))}),!0)},c=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},u=function(){var e=c();return e&&e.activationStart||0},f=function(e,n){var t=c(),r="navigate";o>=0?r="back-forward-cache":t&&(document.prerendering||u()>0?r="prerender":document.wasDiscarded?r="restore":t.type&&(r=t.type.replace(/_/g,"-")));return{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},s=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},t||{})),r}}catch(e){}},d=function(e,n,t,r){var i,o;return function(a){n.value>=0&&(a||r)&&((o=n.value-(i||0))||void 0===i)&&(i=n.value,n.delta=o,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},l=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},p=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},v=function(e){var n=!1;return function(){n||(e(),n=!0)}},m=-1,h=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},g=function(e){"hidden"===document.visibilityState&&m>-1&&(m="visibilitychange"===e.type?e.timeStamp:0,T())},y=function(){addEventListener("visibilitychange",g,!0),addEventListener("prerenderingchange",g,!0)},T=function(){removeEventListener("visibilitychange",g,!0),removeEventListener("prerenderingchange",g,!0)},E=function(){return m<0&&(m=h(),y(),a((function(){setTimeout((function(){m=h(),y()}),0)}))),{get firstHiddenTime(){return m}}},C=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},b=[1800,3e3],S=function(e,n){n=n||{},C((function(){var t,r=E(),i=f("FCP"),o=s("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(o.disconnect(),e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-u(),0),i.entries.push(e),t(!0)))}))}));o&&(t=d(e,i,b,n.reportAllChanges),a((function(r){i=f("FCP"),t=d(e,i,b,n.reportAllChanges),l((function(){i.value=performance.now()-r.timeStamp,t(!0)}))})))}))},L=[.1,.25],w=function(e,n){n=n||{},S(v((function(){var t,r=f("CLS",0),i=0,o=[],c=function(e){e.forEach((function(e){if(!e.hadRecentInput){var n=o[0],t=o[o.length-1];i&&e.startTime-t.startTime<1e3&&e.startTime-n.startTime<5e3?(i+=e.value,o.push(e)):(i=e.value,o=[e])}})),i>r.value&&(r.value=i,r.entries=o,t())},u=s("layout-shift",c);u&&(t=d(e,r,L,n.reportAllChanges),p((function(){c(u.takeRecords()),t(!0)})),a((function(){i=0,r=f("CLS",0),t=d(e,r,L,n.reportAllChanges),l((function(){return t()}))})),setTimeout(t,0))})))},A=0,I=1/0,P=0,M=function(e){e.forEach((function(e){e.interactionId&&(I=Math.min(I,e.interactionId),P=Math.max(P,e.interactionId),A=P?(P-I)/7+1:0)}))},k=function(){return e?A:performance.interactionCount||0},F=function(){"interactionCount"in performance||e||(e=s("event",M,{type:"event",buffered:!0,durationThreshold:0}))},D=[],x=new Map,R=0,B=function(){var e=Math.min(D.length-1,Math.floor((k()-R)/50));return D[e]},H=[],q=function(e){if(H.forEach((function(n){return n(e)})),e.interactionId||"first-input"===e.entryType){var n=D[D.length-1],t=x.get(e.interactionId);if(t||D.length<10||e.duration>n.latency){if(t)e.duration>t.latency?(t.entries=[e],t.latency=e.duration):e.duration===t.latency&&e.startTime===t.entries[0].startTime&&t.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};x.set(r.id,r),D.push(r)}D.sort((function(e,n){return n.latency-e.latency})),D.length>10&&D.splice(10).forEach((function(e){return x.delete(e.id)}))}}},O=function(e){var n=self.requestIdleCallback||self.setTimeout,t=-1;return e=v(e),"hidden"===document.visibilityState?e():(t=n(e),p(e)),t},N=[200,500],j=function(e,n){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(n=n||{},C((function(){var t;F();var r,i=f("INP"),o=function(e){O((function(){e.forEach(q);var n=B();n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},c=s("event",o,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});r=d(e,i,N,n.reportAllChanges),c&&(c.observe({type:"first-input",buffered:!0}),p((function(){o(c.takeRecords()),r(!0)})),a((function(){R=k(),D.length=0,x.clear(),i=f("INP"),r=d(e,i,N,n.reportAllChanges)})))})))},_=[2500,4e3],z={},G=function(e,n){n=n||{},C((function(){var t,r=E(),i=f("LCP"),o=function(e){n.reportAllChanges||(e=e.slice(-1)),e.forEach((function(e){e.startTime<r.firstHiddenTime&&(i.value=Math.max(e.startTime-u(),0),i.entries=[e],t())}))},c=s("largest-contentful-paint",o);if(c){t=d(e,i,_,n.reportAllChanges);var m=v((function(){z[i.id]||(o(c.takeRecords()),c.disconnect(),z[i.id]=!0,t(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return O(m)}),{once:!0,capture:!0})})),p(m),a((function(r){i=f("LCP"),t=d(e,i,_,n.reportAllChanges),l((function(){i.value=performance.now()-r.timeStamp,z[i.id]=!0,t(!0)}))}))}}))},J=[800,1800],K=function e(n){document.prerendering?C((function(){return e(n)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(n)}),!0):setTimeout(n,0)},Q=function(e,n){n=n||{};var t=f("TTFB"),r=d(e,t,J,n.reportAllChanges);K((function(){var i=c();i&&(t.value=Math.max(i.responseStart-u(),0),t.entries=[i],r(!0),a((function(){t=f("TTFB",0),(r=d(e,t,J,n.reportAllChanges))(!0)})))}))},U={passive:!0,capture:!0},V=new Date,W=function(e,i){n||(n=i,t=e,r=new Date,Z(removeEventListener),X())},X=function(){if(t>=0&&t<r-V){var e={entryType:"first-input",name:n.type,target:n.target,cancelable:n.cancelable,startTime:n.timeStamp,processingStart:n.timeStamp+t};i.forEach((function(n){n(e)})),i=[]}},Y=function(e){if(e.cancelable){var n=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){W(e,n),i()},r=function(){i()},i=function(){removeEventListener("pointerup",t,U),removeEventListener("pointercancel",r,U)};addEventListener("pointerup",t,U),addEventListener("pointercancel",r,U)}(n,e):W(n,e)}},Z=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,Y,U)}))},$=[100,300],ee=function(e,r){r=r||{},C((function(){var o,c=E(),u=f("FID"),l=function(e){e.startTime<c.firstHiddenTime&&(u.value=e.processingStart-e.startTime,u.entries.push(e),o(!0))},m=function(e){e.forEach(l)},h=s("first-input",m);o=d(e,u,$,r.reportAllChanges),h&&(p(v((function(){m(h.takeRecords()),h.disconnect()}))),a((function(){var a;u=f("FID"),o=d(e,u,$,r.reportAllChanges),i=[],t=-1,n=null,Z(addEventListener),a=l,i.push(a),X()})))}))};export{L as CLSThresholds,b as FCPThresholds,$ as FIDThresholds,N as INPThresholds,_ as LCPThresholds,J as TTFBThresholds,w as onCLS,S as onFCP,ee as onFID,j as onINP,G as onLCP,Q as onTTFB};