Skip to content

Commit fc4e696

Browse files
authored
Remove broken flot documentation link for Ruby API (#4384)
* Remove broken documentation link for Ruby API https://apidock.com/ruby/Time/to_i is currently down for maintenance But we don't need this link anyway, because it's talking about standard methods. And we plan to deprecate flot_charts altogether: #4267 Signed-off-by: Josh Romero <rmerqg@amazon.com> * remove leftover link brackets Signed-off-by: Josh Romero <rmerqg@amazon.com> --------- Signed-off-by: Josh Romero <rmerqg@amazon.com>
1 parent 0b54e84 commit fc4e696

File tree

1 file changed

+23
-23
lines changed
  • packages/osd-ui-shared-deps/flot_charts

1 file changed

+23
-23
lines changed

packages/osd-ui-shared-deps/flot_charts/API.md

+23-23
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ var options = {
167167
points: { show: true }
168168
}
169169
};
170-
170+
171171
$.plot(placeholder, data, options);
172172
```
173173

@@ -254,10 +254,10 @@ xaxis, yaxis: {
254254
min: null or number
255255
max: null or number
256256
autoscaleMargin: null or number
257-
257+
258258
transform: null or fn: number -> number
259259
inverseTransform: null or fn: number -> number
260-
260+
261261
ticks: null or number or ticks array or (fn: axis -> ticks array)
262262
tickSize: number or array
263263
minTickSize: number or array
@@ -267,7 +267,7 @@ xaxis, yaxis: {
267267
labelWidth: null or number
268268
labelHeight: null or number
269269
reserveSpace: null or true
270-
270+
271271
tickLength: null or number
272272

273273
alignTicksWithAxis: null or number
@@ -415,7 +415,7 @@ ticks: [[0, "zero"], [1.2, "one mark"], [2.4, "two marks"]]
415415
```
416416

417417
You can mix the two if you like.
418-
418+
419419
For extra flexibility you can specify a function as the "ticks"
420420
parameter. The function will be called with an object with the axis
421421
min and max and should return a ticks array. Here's a simplistic tick
@@ -575,7 +575,7 @@ In Python you can get it with something like:
575575
calendar.timegm(datetime_object.timetuple()) * 1000
576576
```
577577
In Ruby you can get it using the `#to_i` method on the
578-
[`Time`](http://apidock.com/ruby/Time/to_i) object. If you're using the
578+
`Time` object. If you're using the
579579
`active_support` gem (default for Ruby on Rails applications) `#to_i` is also
580580
available on the `DateTime` and `ActiveSupport::TimeWithZone` objects. You
581581
simply need to multiply the result by 1000:
@@ -765,7 +765,7 @@ The options inside "series: {}" are copied to each of the series. So
765765
you can specify that all series should have bars by putting it in the
766766
global options, or override it for individual series by specifying
767767
bars in a particular the series object in the array of data.
768-
768+
769769
The most important options are "lines", "points" and "bars" that
770770
specify whether and how lines, points and bars should be shown for
771771
each data series. In case you don't specify anything at all, Flot will
@@ -801,8 +801,8 @@ the y axis if "horizontal" is true), contrary to most other measures
801801
that are specified in pixels. For instance, for time series the unit
802802
is milliseconds so 24 * 60 * 60 * 1000 produces bars with the width of
803803
a day. "align" specifies whether a bar should be left-aligned
804-
(default), right-aligned or centered on top of the value it represents.
805-
When "horizontal" is on, the bars are drawn horizontally, i.e. from the
804+
(default), right-aligned or centered on top of the value it represents.
805+
When "horizontal" is on, the bars are drawn horizontally, i.e. from the
806806
y axis instead of the x axis; note that the bar end points are still
807807
defined in the same way so you'll probably want to swap the
808808
coordinates if you've been plotting vertical bars first.
@@ -1004,7 +1004,7 @@ item: {
10041004
}
10051005
```
10061006
1007-
For instance, if you have specified the data like this
1007+
For instance, if you have specified the data like this
10081008
10091009
```js
10101010
$.plot($("#placeholder"), [ { label: "Foo", data: [[0, 10], [7, 3]] } ], ...);
@@ -1155,7 +1155,7 @@ can call:
11551155
11561156
Returns the calculated offset of the data point at (x, y) in data
11571157
space within the placeholder div. If you are working with multiple
1158-
axes, you can specify the x and y axis references, e.g.
1158+
axes, you can specify the x and y axis references, e.g.
11591159
11601160
```js
11611161
o = pointOffset({ x: xpos, y: ypos, xaxis: 2, yaxis: 3 })
@@ -1215,8 +1215,8 @@ Flot to keep track of its state, so be careful.
12151215
With multiple axes, the extra axes are returned as x2axis, x3axis,
12161216
etc., e.g. getAxes().y2axis is the second y axis. You can check
12171217
y2axis.used to see whether the axis is associated with any data
1218-
points and y2axis.show to see if it is currently shown.
1219-
1218+
points and y2axis.show to see if it is currently shown.
1219+
12201220
- getPlaceholder()
12211221
12221222
Returns placeholder that the plot was put into. This can be useful
@@ -1226,7 +1226,7 @@ Flot to keep track of its state, so be careful.
12261226
12271227
Returns the canvas used for drawing in case you need to hack on it
12281228
yourself. You'll probably need to get the plot offset too.
1229-
1229+
12301230
- getPlotOffset()
12311231

12321232
Gets the offset that the grid has within the canvas as an object
@@ -1242,7 +1242,7 @@ Flot to keep track of its state, so be careful.
12421242
if you modify the values in here, Flot will use the new values.
12431243
If you change something, you probably have to call draw() or
12441244
setupGrid() or triggerRedrawOverlay() to see the change.
1245-
1245+
12461246

12471247
## Hooks ##
12481248

@@ -1254,7 +1254,7 @@ gets access to the internal data structures in Flot.
12541254
Here's an overview of the phases Flot goes through:
12551255

12561256
1. Plugin initialization, parsing options
1257-
1257+
12581258
2. Constructing the canvases used for drawing
12591259

12601260
3. Set data: parsing data specification, calculating colors,
@@ -1270,7 +1270,7 @@ Here's an overview of the phases Flot goes through:
12701270

12711271
7. Responding to events, if any
12721272

1273-
8. Shutdown: this mostly happens in case a plot is overwritten
1273+
8. Shutdown: this mostly happens in case a plot is overwritten
12741274

12751275
Each hook is simply a function which is put in the appropriate array.
12761276
You can add them through the "hooks" option, and they are also available
@@ -1295,22 +1295,22 @@ hooks in the plugins bundled with Flot.
12951295
- processOptions [phase 1]
12961296
12971297
```function(plot, options)```
1298-
1298+
12991299
Called after Flot has parsed and merged options. Useful in the
13001300
instance where customizations beyond simple merging of default
13011301
values is needed. A plugin might use it to detect that it has been
13021302
enabled and then turn on or off other options.
13031303

1304-
1304+
13051305
- processRawData [phase 3]
13061306

13071307
```function(plot, series, data, datapoints)```
1308-
1308+
13091309
Called before Flot copies and normalizes the raw data for the given
13101310
series. If the function fills in datapoints.points with normalized
13111311
points and sets datapoints.pointsize to the size of the points,
13121312
Flot will skip the copying/normalization step for this series.
1313-
1313+
13141314
In any case, you might be interested in setting datapoints.format,
13151315
an array of objects for specifying how a point is normalized and
13161316
how it interferes with axis scaling. It accepts the following options:
@@ -1430,7 +1430,7 @@ hooks in the plugins bundled with Flot.
14301430
state by drawing something (add a drawOverlay hook and call
14311431
triggerRedrawOverlay) or firing an externally visible event for
14321432
user code. See the crosshair plugin for an example.
1433-
1433+
14341434
Currently, eventHolder actually contains both the static canvas
14351435
used for the plot itself and the overlay canvas used for
14361436
interactive features because some versions of IE get the stacking
@@ -1469,7 +1469,7 @@ hooks in the plugins bundled with Flot.
14691469
add a callback to clean up after you. Take a look at the section in
14701470
the [PLUGINS](PLUGINS.md) document for more info.
14711471

1472-
1472+
14731473
## Plugins ##
14741474

14751475
Plugins extend the functionality of Flot. To use a plugin, simply

0 commit comments

Comments
 (0)