diff -r a41d76310c7d -r d8b6ea26da6e wwwcorpus/metadataplayer/HelloWorld.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/wwwcorpus/metadataplayer/HelloWorld.js Tue Mar 18 14:08:02 2014 +0100 @@ -0,0 +1,33 @@ +/* Shows an example of a widget, with : + * - Use of source data + * - Use of templating + * - Use of internationalization + */ + +IriSP.Widgets.HelloWorld = function(player, config) { + console.log("Calling IriSP.Widget's constructor from IriSP.HelloWorldWidget"); + IriSP.Widgets.Widget.call(this, player, config); +}; + +IriSP.Widgets.HelloWorld.prototype = new IriSP.Widgets.Widget(); + +IriSP.Widgets.HelloWorld.prototype.defaults = { + text: "world" +}; + +IriSP.Widgets.HelloWorld.prototype.template = + '
{{l10n.Hello}} {{text}}
Looks like we have {{source.contents.annotation.length}} annotations in this feed