Browse Source

Fixed #964: `Timeline`, `Graph2d`, and `Network` not working on IE9

flowchartTest
jos 8 years ago
parent
commit
96afb72d17
3 changed files with 21 additions and 11 deletions
  1. +3
    -2
      HISTORY.md
  2. +12
    -6
      lib/shared/ColorPicker.js
  3. +6
    -3
      lib/shared/Configurator.js

+ 3
- 2
HISTORY.md View File

@ -2,11 +2,12 @@
http://visjs.org
## NOT YET RELEASED, verions 4.2.1--SNAPSHOT
## NOT YET RELEASED, version 4.2.1--SNAPSHOT
### General
- Fixed #950: option `locales` broken in `Timeline`, `Graph2d`, and `Network`.
- Fixed #964: `Timeline`, `Graph2d`, and `Network` not working on IE9.
### Graph2d
@ -45,7 +46,7 @@ http://visjs.org
- Added releaseFunction to openCluster.
- Fixed bug where the network could flicker when the pixelRatio is not integer.
- Added enabled property to physics.
- Fixed #927, dragStart event didnt contain node that was being dragged
- Fixed #927, dragStart event didn't contain node that was being dragged
## 2015-05-28, version 4.1.0

+ 12
- 6
lib/shared/ColorPicker.js View File

@ -339,16 +339,22 @@ class ColorPicker {
this.arrowDiv.className = 'vis-arrow';
this.opacityRange = document.createElement('input');
this.opacityRange.type = 'range';
this.opacityRange.min = '0';
this.opacityRange.max = '100';
try {
this.opacityRange.type = 'range'; // Not supported on IE9
this.opacityRange.min = '0';
this.opacityRange.max = '100';
}
catch (err) {}
this.opacityRange.value = '100';
this.opacityRange.className = 'vis-range';
this.brightnessRange = document.createElement('input');
this.brightnessRange.type = 'range';
this.brightnessRange.min = '0';
this.brightnessRange.max = '100';
try {
this.brightnessRange.type = 'range'; // Not supported on IE9
this.brightnessRange.min = '0';
this.brightnessRange.max = '100';
}
catch (err) {}
this.brightnessRange.value = '100';
this.brightnessRange.className = 'vis-range';

+ 6
- 3
lib/shared/Configurator.js View File

@ -310,10 +310,13 @@ class Configurator {
let max = arr[2];
let step = arr[3];
let range = document.createElement('input');
range.type = 'range';
range.className = 'vis-network-configuration range';
range.min = min;
range.max = max;
try {
range.type = 'range'; // not supported on IE9
range.min = min;
range.max = max;
}
catch (err) {}
range.step = step;
if (value !== undefined) {

Loading…
Cancel
Save