Browse Source

Merge branch 'develop' of https://github.com/almende/vis into develop

revert-3409-performance
Yotam Berkowitz 7 years ago
parent
commit
b110a055a1
4 changed files with 61 additions and 7 deletions
  1. +37
    -0
      HISTORY.md
  2. +20
    -1
      examples/timeline/items/expectedVsActualTimesItems.html
  3. +3
    -5
      lib/timeline/component/Group.js
  4. +1
    -1
      package.json

+ 37
- 0
HISTORY.md View File

@ -1,6 +1,43 @@
# vis.js history
http://visjs.org
## 2017-07-01, version 4.20.1
### General
- Added Release checklist
- Added collapsible items for objects in graph3d doc
### Network
- FIX #3203: Set dimensions properly of images on initialization
- FIX #3198: Small fix on ref usage in DataGroup
- FIX #3170: Refactoring of Node Drawing
- FIX #3108: Reverse nodes returned with 'from' and 'to' directions
- FIX #3122: Refactored line drawing for Bezier edges
- FIX #3121: Refactoring of `BezierEdgeStatic._getViaCoordinates()`
- FIX #3088: Consolidate code for determining the pixel ratio
- FIX #3036: Smooth type 'dynamic' adjusted for node-specific option in hierarchical
- FIX #1105: Fix usage of clustering with hierarchical networks
- FIX #3133: Protect Network from zero and negative mass values
- FIX #3163: Prevent crashes from invalid id's in `Clustering.findNode()`
- FIX #3106: Ensure start and end of stabilization progress events is sent
- FIX #3015: Properly handle newline escape sequences in strings for DOT
- FIX Refactoring of LayoutEngine
- FIX #2990: Edge labels turn bold on select and hover
- FIX #2959: Changed order of (de)select events for network
- FIX #3091: Added param 'direction' to Network.getConnectedNodes()
- FIX #3085: Add prefix to cancelAnimationFrame()
### Graph3D
- FIX #2804: Add data group class to Graph3d
### Timeline
- FIX #3172: Fix stacking when setting option
- FIX #3183: Fixes a race condition that set an item's group to be set to undefined
- FEAT #3154: Caching to Range getMillisecondsPerPixel function
- FIX #3105: Adjusting timeline TimeStep.roundToMinor
- FEAT #3107: Allow overriding `align` per item
## 2017-05-21, version 4.20.0
### General

+ 20
- 1
examples/timeline/items/expectedVsActualTimesItems.html View File

@ -85,13 +85,32 @@
group:'group1',
subgroup:'sg_2'
},
{
{
id: 4,
content: 'item 2 (actual time)',
start: '2014-01-14T12:00:00',
end: '2014-01-17T12:00:00',
group:'group1',
subgroup:'sg_2'
},
// subgroup 3
{
id: 5,
content: 'item 3 (expected time)',
className: 'expected',
start: '2014-01-17T12:00:00',
end: '2014-01-19T12:00:00',
group:'group1',
subgroup:'sg_3'
},
{
id: 6,
content: 'item 3 (actual time)',
start: '2014-01-17T12:00:00',
end: '2014-01-18T12:00:00',
group:'group1',
subgroup:'sg_3'
}
]);

+ 3
- 5
lib/timeline/component/Group.js View File

@ -246,6 +246,7 @@ Group.prototype.redraw = function(range, margin, forceRestack) {
var restack = forceRestack || this.stackDirty || (this.isVisible && !lastIsVisible);
this._updateSubgroupsSizes();
// if restacking, reposition visible items vertically
if(restack) {
if (typeof this.itemSet.options.order === 'function') {
@ -285,9 +286,6 @@ Group.prototype.redraw = function(range, margin, forceRestack) {
this.stackDirty = false;
}
this._updateSubgroupsSizes();
// recalculate the height of the group
var height = this._calculateHeight(margin);
@ -486,7 +484,7 @@ Group.prototype._updateSubgroupsSizes = function () {
if (me.subgroups) {
for (var subgroup in me.subgroups) {
var newStart = me.subgroups[subgroup].items[0].data.start;
var newEnd = me.subgroups[subgroup].items[0].data.end;
var newEnd = me.subgroups[subgroup].items[0].data.end - 1;
me.subgroups[subgroup].items.forEach(function(item) {
if (new Date(item.data.start) < new Date(newStart)) {
@ -498,7 +496,7 @@ Group.prototype._updateSubgroupsSizes = function () {
})
me.subgroups[subgroup].start = newStart;
me.subgroups[subgroup].end = newEnd;
me.subgroups[subgroup].end = new Date(newEnd - an class="mi">1) // -1 to compensate for colliding end to start subgroups;
}
}

+ 1
- 1
package.json View File

@ -1,6 +1,6 @@
{
"name": "vis",
"version": "4.20.1-SNAPSHOT",
"version": "4.20.1",
"description": "A dynamic, browser-based visualization library.",
"homepage": "http://visjs.org/",
"license": "(Apache-2.0 OR MIT)",

Loading…
Cancel
Save