Fix TypeScript 2.4 errors, introduced mainly due weak types and covariant checking for callbacks (#4476)

This commit is contained in:
Panayot Cankov
2017-07-03 11:57:00 +03:00
committed by Alexander Vakrilov
parent 9e6498c29a
commit 8adb2fdfef
20 changed files with 92 additions and 23 deletions

View File

@@ -45,7 +45,7 @@ export interface CssAnimationPropertyOptions<T, U> {
readonly valueConverter?: (value: string) => U;
}
export class Property<T extends ViewBase, U> implements TypedPropertyDescriptor<U> {
export class Property<T extends ViewBase, U> {
constructor(options: PropertyOptions<T, U>);
public readonly getDefault: symbol;
@@ -55,12 +55,16 @@ export class Property<T extends ViewBase, U> implements TypedPropertyDescriptor<
public nativeValueChange(T, U): void;
public isSet(instance: T): boolean;
}
export interface Property<T extends ViewBase, U> extends TypedPropertyDescriptor<U> {
}
export class CoercibleProperty<T extends ViewBase, U> extends Property<T, U> implements TypedPropertyDescriptor<U> {
export class CoercibleProperty<T extends ViewBase, U> extends Property<T, U> {
constructor(options: CoerciblePropertyOptions<T, U>);
public readonly coerce: (target: T) => void;
}
export interface CoercibleProperty<T extends ViewBase, U> extends TypedPropertyDescriptor<U> {
}
export class InheritedProperty<T extends ViewBase, U> extends Property<T, U> {
constructor(options: PropertyOptions<T, U>);