mirror of
https://github.com/konvajs/konva.git
synced 2025-06-28 06:31:15 +08:00
Merge pull request #1826 from tbo47/add-types
add types and remove unused import
This commit is contained in:
commit
b379efe0df
@ -1,6 +1,6 @@
|
|||||||
import { Konva } from './Global';
|
import { Konva } from './Global';
|
||||||
import { Context } from './Context';
|
import { Context } from './Context';
|
||||||
import { IRect, RGB, RGBA, Vector2d } from './types';
|
import { IRect, RGB, Vector2d } from './types';
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Last updated November 2011
|
* Last updated November 2011
|
||||||
|
@ -2,7 +2,7 @@ import { Factory } from '../Factory';
|
|||||||
import { Node, Filter } from '../Node';
|
import { Node, Filter } from '../Node';
|
||||||
import { getNumberValidator } from '../Validators';
|
import { getNumberValidator } from '../Validators';
|
||||||
|
|
||||||
function remap(fromValue, fromMin, fromMax, toMin, toMax) {
|
function remap(fromValue: number, fromMin: number, fromMax: number, toMin: number, toMax: number) {
|
||||||
// Compute the range of the data
|
// Compute the range of the data
|
||||||
var fromRange = fromMax - fromMin,
|
var fromRange = fromMax - fromMin,
|
||||||
toRange = toMax - toMin,
|
toRange = toMax - toMin,
|
||||||
|
Loading…
Reference in New Issue
Block a user