diff --git a/scripts/build-widget-reference.js b/scripts/build-widget-reference.js
index d6d1d7ff..855f9795 100644
--- a/scripts/build-widget-reference.js
+++ b/scripts/build-widget-reference.js
@@ -36,8 +36,32 @@ LANG = 'en'
// Here we go
var widgets = require('../src/browser/js/app/widgets'),
- doc = '',
- first
+ base = require('../src/browser/js/app/widgets/common/widget').defaults(),
+ doc = ''
+
+
+doc += '\n\n'
+doc += '## Generic properties'
+doc += '\n\n'
+
+doc += '| property | type |default | description |'
+doc += '\n'
+doc += '| --- | --- | --- | --- |'
+
+for (var propName in base) {
+
+ var prop = base[propName],
+ permalink = propName
+
+ if (propName === '_props' || propName[0] === '_') continue
+
+ var help = Array.isArray(prop.help) ? prop.help.join('
').replace(/
-/g, '-') : prop.help || ''
+
+ doc += '\n'
+ doc += `|
${(JSON.stringify(prop.value, null, ' ') || '').replace(/\n/g,'
')} | ${help} |`
+
+}
+
for (var k in widgets.categories) {
var category = widgets.categories[k]
@@ -62,12 +86,12 @@ for (var k in widgets.categories) {
var prop = defaults[propName],
permalink = type + '_' + propName
- if (propName === '_props' || propName === 'type' || propName[0] === '_') continue
+ if (propName === '_props' || propName[0] === '_' || JSON.stringify(prop) == JSON.stringify(base[propName])) continue
- var help = Array.isArray(prop.help) ? prop.help.join('${(JSON.stringify(prop.value, null, ' ') || '').replace(/\n/g,'
')} | ${help} |`
+ doc += `| ${(JSON.stringify(prop.value, null, ' ') || '').replace(/\n/g,'
')} | ${help} |`
}