From d96bbe5296a1462ee21072630cddae5e6c5c11d4 Mon Sep 17 00:00:00 2001 From: jos Date: Thu, 7 May 2015 14:29:56 +0200 Subject: [PATCH] Some fixes in the validator --- lib/timeline/Core.js | 1 + lib/timeline/options.js | 20 +++++++++++++------- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/lib/timeline/Core.js b/lib/timeline/Core.js index 2e0fb77c..64ff983e 100644 --- a/lib/timeline/Core.js +++ b/lib/timeline/Core.js @@ -291,6 +291,7 @@ Core.prototype.setOptions = function (options) { util.deepExtend(appliedOptions, component.options); }); this.configurationSystem.setModuleOptions({global: appliedOptions}); + console.log(appliedOptions) } // redraw everything diff --git a/lib/timeline/options.js b/lib/timeline/options.js index 750f84c8..c2d19d02 100644 --- a/lib/timeline/options.js +++ b/lib/timeline/options.js @@ -32,7 +32,13 @@ let allOptions = { autoResize: {boolean}, clickToUse: {boolean}, dataAttributes: {string, array}, - editable: {boolean, object}, + editable: { + add: {boolean, undef}, + remove: {boolean, undef}, + updateGroup: {boolean, undef}, + updateTime: {boolean, undef}, + __type__: {boolean, object} + }, end: {number, date, string, moment}, format: { minorLabels: { @@ -70,8 +76,8 @@ let allOptions = { margin: { axis: {number}, item: { - horizontal: {number}, - vertical: {number}, + horizontal: {number,undef}, + vertical: {number,undef}, __type__: {object,number} }, __type__: {object,number} @@ -89,8 +95,8 @@ let allOptions = { onRemove: {fn}, order: {fn}, orientation: { - axis: {string}, - item: {string}, + axis: {string,undef}, + item: {string,undef}, __type__: {string, object} }, selectable: {boolean}, @@ -102,8 +108,8 @@ let allOptions = { start: {date, number, string, moment}, template: {fn}, timeAxis: { - scale: {string}, - step: {number}, + scale: {string,undef}, + step: {number,undef}, __type__: {object} }, type: {string},