Releases: palantir/plottable
ModifiedLog Scales
ModifiedLog
This release adds Plottable.Scale.ModifiedLog
, which can be used the same way as a Plottable.Scale.Linear
:
var yScale = new Plottable.Scale.ModifiedLog();
...
A ModifiedLog
scale behaves mostly the same as a log scale, but as x
approaches 0
, modifiedLog(x)
approaches 0
instead of -Infinity
. For a more in-depth explanation, see #710.
ModifiedLog
is intended as a replacement for Plottable.Scale.Log
, which is very buggy due to not being able to handle 0
and negative numbers.
API changes
Plottable.Scale.ModifiedLog
class has been added, to be used the same way as anyQuantitiveScale
.Plottable.Scale.ModifiedLog.showIntermediateTicks(bool)
has been added. By default,ModifiedLog
only shows ticks on powers of10
, like[10, 100, 1000]
. Ifscale.showIntermediateTicks(true)
is called, it will show ticks in between, like[10, 30, 70, 100, 300, 700, 1000]
.Plottable.Scale.Log
is deprecated.
Release Song
Minor Bugfixes
Scale.autoDomain
now deals with nonlinear scales intelligently- All calls to
console.log
have been replaced withUtil.Methods.warn
, which is safe to use in IE9 - We now have automated cross browser testing in saucelabs
Fix CSS for Plottable tooltip to avoid conflict with blueprint
v0.20.3-hover-tooltip-1 Force Plottable Tooltips to be opaque
Demo implementation of hover tooltips for Slate
Not ready for general release.
Currently tooltips only work on VerticalBar and HorizontalBar plots. To use them, project the desired tooltip text on to "tooltip-text":
barPlot.project("tooltip-text", "x"); // displays the x value as the tooltip
barPlot.project("tooltip-text", (d: any) => String(d.x).toUpperCase); // all caps
Scale Autowarnings
QuantitiveScales now warn if their domain is being set to include invalid values
Formatters accessible from Axis.Numeric
Axis.Numeric now exposes the formatter as a getter/setter
Update Numeric Axis type signature
The Plottable.Axis.Numeric class now appropriately takes any
as a formatter.
Correct Git mistakes
- BaseAxis now actually will upgrade custom format functions into custom Plottable.Formatters
- XAxis and YAxis are actually removed
Gone with the Wind
This release focuses on removal.
Component.remove
and Component.detach
Previously, calling .remove
on a component would not destroy the component, but would temporarily detach it from the DOM. All listeners would be maintained on the removed Component. Now, that functionality is maintained by Component.detach
. Calling remove
will detach the component, and additionally deregister all its listeners and make it impossible to use in the future. Using remove is the correct API point to avoid memory leaks.
Axis.XAxis
and Axis.YAxis
We've removed the XAxis
and YAxis
classes, in favor of the more general Axis.Numeric
and Axis.Category
.
Bugfixes & API Cleanup
- Fixed a bug where
Domainer.paddingExceptions
were not handled properly if multiple plots registered the samepaddingException
LinePlot
andAreaPlot
now animate up from the appropriate location.Axis.Category
will now use formatters appropriatelyAxis.Numeric
no longer forces the scale to return around 10 ticks, so callingQuantitiveScale.ticks(count)
will now change how many ticks exist on the axis.
API Cleanup
Label.setText
has been renamed toLabel.text
and converted into a getter/setter- The
Formatter.Custom
constructor now takes the custom format function as the first argument, and only optionally requires precision - Plottable now exposes a
version
property.
Fix version number
Fix the version number. Oh, the shame.