* Uses the current domain of the scale to apply a minimum and maximum * domain value for that scale. * * This constrains the pan/zoom interaction to show no more than the domain * of the scale.
(scale: TransformableScale<any, number>)
| 635 | * of the scale. |
| 636 | */ |
| 637 | public setMinMaxDomainValuesTo(scale: TransformableScale<any, number>) { |
| 638 | this._minDomainValues.delete(scale); |
| 639 | this._maxDomainValues.delete(scale); |
| 640 | const [ domainMin, domainMax ] = scale.getTransformationDomain(); |
| 641 | this.minDomainValue(scale, domainMin); |
| 642 | this.maxDomainValue(scale, domainMax); |
| 643 | return this; |
| 644 | } |
| 645 | |
| 646 | /** |
| 647 | * Adds a callback to be called when panning ends. |
no test coverage detected