X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Fmkws-widget-termlists.js;h=3ea68f5cbbeca4fe0611a9be6791bb9a1a3ceb85;hb=dc84bbb2775213f91758de6e96ab95713d612cbe;hp=4250f88993332523d1915f4b9a41ab995e9b4464;hpb=85f601df4d3c610a4441e8002192cd78e6bcb3a0;p=mkws-moved-to-github.git diff --git a/src/mkws-widget-termlists.js b/src/mkws-widget-termlists.js index 4250f88..3ea68f5 100644 --- a/src/mkws-widget-termlists.js +++ b/src/mkws-widget-termlists.js @@ -1,35 +1,48 @@ -mkws.facetConfig = { - xtargets: [ "Sources", 16, false ], - subject: [ "Subjects", 10, true ], - author: [ "Authors", 10, true ] -} - - mkws.registerWidgetType('Termlists', function() { var that = this; - var facets = that.config.facets; + // Initially hide the termlists; display when we get results + $(document).ready(function() { + $(that.node).hide(); + }); this.team.queue("termlists").subscribe(function(data) { - // display if we first got results $(that.node).show(); }); - widget.autosearch(that); + var acc = []; + var facets = this.config.facets; + acc.push('