material-motion
Version:
Makes it easy to add rich, interactive motion to your application.
11 lines (10 loc) • 635 B
TypeScript
import { Constructor, MotionReactiveMappable, Observable, ObservableWithMotionOperators, Point2D, PolarCoords } from '../types';
export declare type ToPolarOrigin<T> = (T & Point2D) | (Observable<T & Point2D>);
export declare type ToPolarArgs<T> = {
origin$: ToPolarOrigin<T>;
};
export interface MotionPolarizable<T> {
toPolar(kwargs: ToPolarArgs<T>): ObservableWithMotionOperators<PolarCoords>;
toPolar(origin$: ToPolarOrigin<T>): ObservableWithMotionOperators<PolarCoords>;
}
export declare function withToPolar<T, S extends Constructor<MotionReactiveMappable<T>>>(superclass: S): S & Constructor<MotionPolarizable<T>>;