Download the PHP package quazardous/activity-heatmap without Composer
On this page you can find all versions of the php package quazardous/activity-heatmap. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download quazardous/activity-heatmap
More information about quazardous/activity-heatmap
Files in quazardous/activity-heatmap
Package activity-heatmap
Short Description A d3 heatmap for representing time series data
License MIT
Informations about the package activity-heatmap
Activity heatmap
A(nother) d3.js heatmap representing time series data. Inspired by Github's contribution chart
Inspired by the excellent DKirwan's Calendar Heatmap.
Reworked for d3.js v5 + ES6 class style.
Screenshot
Yearly profile.
Monthly profile.
Features & specs
- Heatmap
- Histogram
- Labels and scales
- Free time granularity
- Clean coding... (well tell me)
- Easy to tweak with options and profiles
- Fully localizable (uses only
moment.format()
)
Dependencies
Usage
-
Add
d3.js
andmoment.js
-
Include
activity-heatmap.js
<script src="path/to/activity-heatmap.js"></script>
or<script src="path/to/activity-heatmap.min.js"></script>
-
Add style stuff for tooltips
-
Add some container
<div id="my-heatmap"></div>
- Create the heatmap with some data
Options
The second arg is a profile hint that will tweak options. You can override the tweaked options after instantiation.
The third arg can be an extensive options object.
Final computations will be done at render time.
Here is some common options:
Inline render()
render()
can be use without arguments or you can pass your own SVG
object.
It returns a SVG group with the whole heatmap.
Example
Open examples/ex1.html
.
NB: if you open ex1.html
as local file, you may need to bypass CORS
(With FF: about:config
> privacy.file_unique_origin
=> false).