You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+12-7
Original file line number
Diff line number
Diff line change
@@ -23,7 +23,7 @@ You can also use bower package manager:
23
23
__Important!__ You need to set flot option `hoverable` to `true` if you want flot.tooltip plugin to work.
24
24
25
25
grid: {
26
-
hoverable: true
26
+
hoverable: true
27
27
}
28
28
29
29
### Plugin Options
@@ -50,15 +50,15 @@ In comments there are default values
50
50
51
51
52
52
-`show` : set to `true` to turn on this plugin (if `grid.hoverable` is also set to `true`)
53
-
-`cssClass` : the class to assign to the tooltip's HTML DIV element, defaulted to "flotTip"
53
+
-`cssClass` : the class to assign to the tooltip's HTML DIV element, defaulted to "flotTip"
54
54
-`content` : content of your tooltip, HTML tags are also allowed; use `%s` for series label, `%x` for X value, `%y` for Y value and `%p` for percentage value (useful with pie charts using flot.pie plugin)
55
55
With `%x`, `%y` and `%p` values you can also use `.precision`, for example `%x.2` means that value of X will be rounded to 2 digits after the decimal point.
56
56
If no precision or dateFormat is set then plugin uses tickFormatter to format values displayed on tooltip.
57
57
If you require even more control over how the tooltip is generated you can pass a callback `function(label, xval, yval, flotItem)` that must return a string with the format described.
58
58
The content callback function pass may also return a boolean value of false (or empty string) if the tooltip is to be hidden for the given data point.
59
59
Pull request [#64](https://github.com/krzysu/flot.tooltip/pull/64) introduced two more placeholders `%lx` and `%ly`, that work with flot-axislabels plugin.
60
60
Pull request [#75](https://github.com/krzysu/flot.tooltip/pull/75) introduced `%ct` placeholder for any custom text withing label (see example in `examples/custom-label-text.html`)
61
-
Pull request [#112](https://github.com/krzysu/flot.tooltip/pull/112) introduced `%n` placeholder for the total number (rather than percent) represented by a single slice of a pie chart.
61
+
Pull request [#112](https://github.com/krzysu/flot.tooltip/pull/112) introduced `%n` placeholder for the total number (rather than percent) represented by a single slice of a pie chart.
62
62
-`xDateFormat` : you can use the same specifiers as in Flot, for time mode data
63
63
-`yDateFormat` : you can use the same specifiers as in Flot, for time mode data
@@ -166,7 +170,7 @@ when the pull request is merged and how many other changes were made at the same
166
170
167
171
### v0.6 and v0.6.1
168
172
169
-
- nothing from user perspective :)
173
+
- nothing from user perspective :)
170
174
- another refactoring, `FlotTooltip` object structure changed to allow many instances to fix issue #13 (regression after v0.5 refactoring)
171
175
172
176
### v0.5.1
@@ -204,7 +208,7 @@ when the pull request is merged and how many other changes were made at the same
204
208
### v0.4
205
209
206
210
Now you can easily set precision of values displayed on tip thanks to enhanced _string formatter_.
207
-
Just put your desired precision after value in format like this `%x.precision`,
211
+
Just put your desired precision after value in format like this `%x.precision`,
208
212
where _precision_ is a number of digits to appear after the decimal point. It uses `number.toFixed(precision)` function internally.
209
213
210
214
What is more _string formatter_ was rewritten and now is RegExp based.
@@ -257,8 +261,9 @@ From now on also minified version is available.
257
261
-[@willianganzert](https://github.com/willianganzert) - pull request [#83](https://github.com/krzysu/flot.tooltip/pull/83), Add "id" to tooltip element
258
262
-[@larsenmtl](https://github.com/larsenmtl) - pull request [#85](https://github.com/krzysu/flot.tooltip/pull/85), Support for stacked percent plugin
259
263
-[@RoboterHund](https://github.com/RoboterHund) - pull request [#87](https://github.com/krzysu/flot.tooltip/pull/86), Compatibility fix for older versions of jQuery
264
+
- and many more, check merged pull requests
260
265
261
266
* * *
262
-
Copyright (c) 2011-2014 Krzysztof Urbas (@krzysu) & Evan Steinkerchner (@Roundaround).
267
+
Copyright (c) 2011-2016 Krzysztof Urbas (@krzysu) & Evan Steinkerchner (@Roundaround).
263
268
264
269
__jquery.flot.tooltip__ is available under the MIT license.
0 commit comments