(
// If input `null/undefined`, a mapper will be created.
mapper: ScaleMapper | NullUndefined,
initialExtent: number[] | NullUndefined
)
| 399 | } |
| 400 | |
| 401 | export function initLinearScaleMapper( |
| 402 | // If input `null/undefined`, a mapper will be created. |
| 403 | mapper: ScaleMapper | NullUndefined, |
| 404 | initialExtent: number[] | NullUndefined |
| 405 | ): ScaleMapper { |
| 406 | const linearMapper = (mapper || {}) as LinearScaleMapper; |
| 407 | |
| 408 | const extendList: number[][] = []; |
| 409 | // @ts-ignore |
| 410 | linearMapper._extents = extendList; |
| 411 | |
| 412 | extendList[SCALE_EXTENT_KIND_EFFECTIVE] = initialExtent ? initialExtent.slice() : initExtentForUnion(); |
| 413 | |
| 414 | extend(linearMapper, linearScaleMapperMethods); |
| 415 | |
| 416 | return linearMapper; |
| 417 | } |
| 418 | |
| 419 | const linearScaleMapperMethods: ScaleMapperGeneric<LinearScaleMapper> = { |
| 420 |
no test coverage detected
searching dependent graphs…