File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -123,9 +123,9 @@ const createStopperStyle = function(): HTMLStyleElement {
123
123
124
124
/**
125
125
* After function calls to obj[prop], calls the callback with the return value.
126
- * @param { !Object } obj
127
- * @param { string } prop
128
- * @param { function(*) } callback
126
+ * @param obj
127
+ * @param prop
128
+ * @param callback
129
129
*/
130
130
function after ( obj : Object , prop : string , callback : Function ) {
131
131
if ( ! ( prop in obj ) ) {
Original file line number Diff line number Diff line change 14
14
* limitations under the License.
15
15
*/
16
16
17
- export async function imgLoadPromise ( img ) {
17
+ export async function imgLoadPromise ( img : HTMLImageElement ) : Promise < void > {
18
18
if ( img . complete ) {
19
19
return ;
20
20
}
21
21
22
- return new Promise ( ( resolve , reject ) => {
22
+ return new Promise < void > ( ( resolve , reject ) => {
23
23
function finish ( ) {
24
24
img . removeEventListener ( 'load' , load ) ;
25
25
img . removeEventListener ( 'error' , error ) ;
@@ -38,4 +38,4 @@ export async function imgLoadPromise(img) {
38
38
img . addEventListener ( 'load' , load ) ;
39
39
img . addEventListener ( 'error' , error ) ;
40
40
} ) ;
41
- }
41
+ }
You can’t perform that action at this time.
0 commit comments