Skip to content

Commit

Permalink
Build 3.3.6
Browse files Browse the repository at this point in the history
  • Loading branch information
wa0x6e committed Oct 29, 2013
1 parent 5d9bce2 commit 4fe8184
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 8 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## v3.3.6 [2013-10-28]

* [new] Add `destroy()` method

## v3.3.5 [2013-10-16]

* [new] Add `highlight()` method to change highlighted date after calendar initialization
Expand Down
42 changes: 39 additions & 3 deletions cal-heatmap.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! cal-heatmap v3.3.5 (Wed Oct 16 2013 23:56:23)
/*! cal-heatmap v3.3.6 (Mon Oct 28 2013 22:39:46)
* ---------------------------------------------
* Cal-Heatmap is a javascript module to create calendar heatmap to visualize time series data
* https://github.com/kamisama/cal-heatmap
Expand Down Expand Up @@ -2708,6 +2708,15 @@ CalHeatMap.prototype = {
return true;
},

/**
* Highlight dates
*
* Add a highlight class to a set of dates
*
* @since 3.3.5
* @param array Array of dates to highlight
* @return bool True if dates were highlighted
*/
highlight: function(args) {
"use strict";

Expand All @@ -2718,6 +2727,34 @@ CalHeatMap.prototype = {
return false;
},

/**
* Destroy the calendar
*
* Usage: cal = cal.destroy();
*
* @since 3.3.6
* @param function A callback function to trigger after destroying the calendar
* @return null
*/
destroy: function(callback) {
"use strict";

this.root.transition().duration(this.options.animationDuration)
.attr("width", 0)
.attr("height", 0)
.remove()
.each("end", function() {
if (typeof callback === "function") {
callback();
} else {
console.log("Provided callback for destroy() is not a function.");
}
})
;

return null;
},

getSVG: function() {
"use strict";

Expand Down Expand Up @@ -2774,8 +2811,7 @@ CalHeatMap.prototype = {
continue;
}

// The DOM Level 2 CSS wa
// y
// The DOM Level 2 CSS way
/* jshint maxdepth: false */
if ("getComputedStyle" in window) {
var cs = getComputedStyle(dom, null);
Expand Down
4 changes: 2 additions & 2 deletions cal-heatmap.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion cal-heatmap.source-map.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cal-heatmap",
"version": "3.3.5",
"version": "3.3.6",
"description": "Cal-Heatmap is a javascript module to create calendar heatmap to visualize time series data",
"keywords": [
"calendar",
Expand Down
2 changes: 1 addition & 1 deletion test/test.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! cal-heatmap v3.3.5 (Mon Oct 28 2013 22:10:36)
/*! cal-heatmap v3.3.6 (Mon Oct 28 2013 22:39:46)
* ---------------------------------------------
* Cal-Heatmap is a javascript module to create calendar heatmap to visualize time series data
* https://github.com/kamisama/cal-heatmap
Expand Down

0 comments on commit 4fe8184

Please sign in to comment.