mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-12-01 02:37:05 +00:00
Merge "Update typescript to latest (v4.5.5)"
This commit is contained in:
commit
e4b73894b8
17677
package-lock.json
generated
17677
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -35,7 +35,7 @@
|
|||
"pre-commit": "1.2.2",
|
||||
"stylelint-config-wikimedia": "0.11.1",
|
||||
"svgo": "2.3.1",
|
||||
"typescript": "3.8.3",
|
||||
"typescript": "4.5.5",
|
||||
"vue": "2.6.11"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
/** See Vector\Hooks::getVectorResourceLoaderConfig */
|
||||
interface VectorResourceLoaderVirtualConfig {
|
||||
wgVectorSearchHost: string;
|
||||
/**
|
||||
* The name of the ResourceLoader module that contains search.
|
||||
*/
|
||||
|
|
|
@ -16,7 +16,9 @@ var /** @type {VectorResourceLoaderVirtualConfig} */
|
|||
CAN_TEST_SEARCH = !!(
|
||||
window.performance &&
|
||||
/* eslint-disable compat/compat */
|
||||
// @ts-ignore
|
||||
performance.mark &&
|
||||
// @ts-ignore
|
||||
performance.measure &&
|
||||
performance.getEntriesByName ),
|
||||
/* eslint-enable compat/compat */
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* global FetchEndEvent, SuggestionClickEvent, SubmitEvent */
|
||||
/* global FetchEndEvent, SuggestionClickEvent, SearchSubmitEvent */
|
||||
/** @module Instrumentation */
|
||||
|
||||
/**
|
||||
|
@ -13,10 +13,14 @@ var INPUT_LOCATION_MOVED = 'header-moved',
|
|||
// mediawiki.searchSuggest performance. Marks and Measures will only be
|
||||
// recorded on the Vector skin and only if browser supported.
|
||||
shouldTestSearchPerformance = !!( window.performance &&
|
||||
// @ts-ignore
|
||||
window.requestAnimationFrame &&
|
||||
/* eslint-disable compat/compat */
|
||||
// @ts-ignore
|
||||
performance.mark &&
|
||||
// @ts-ignore
|
||||
performance.measure &&
|
||||
// @ts-ignore
|
||||
performance.getEntriesByName &&
|
||||
performance.clearMarks ),
|
||||
/* eslint-enable compat/compat */
|
||||
|
@ -88,7 +92,7 @@ function onFetchEnd( event ) {
|
|||
}
|
||||
|
||||
/**
|
||||
* @param {SuggestionClickEvent|SubmitEvent} event
|
||||
* @param {SuggestionClickEvent|SearchSubmitEvent} event
|
||||
*/
|
||||
function onSuggestionClick( event ) {
|
||||
mw.track( 'mediawiki.searchSuggest', {
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
*/
|
||||
|
||||
/**
|
||||
* @typedef {SuggestionClickEvent} SubmitEvent
|
||||
* @typedef {SuggestionClickEvent} SearchSubmitEvent
|
||||
*/
|
||||
|
||||
/* exported SuggestionClickEvent, SubmitEvent, FetchEndEvent */
|
||||
/* exported SuggestionClickEvent, SuggestionSubmitEvent, FetchEndEvent */
|
||||
|
|
Loading…
Reference in a new issue