blob: b0b2e2a236748331d4d7baae3ee677a48364518b [file] [log] [blame]
Akron479994e2018-07-02 13:21:44 +02001requirejs.config({
2 baseUrl: '/js/src',
3 paths : {
4 'lib': '../lib'
5 }
6});
7
hebastae094dc62019-12-06 13:12:40 +01008
9
10
11define(['app/en','match', 'panel/match', 'panel/result', 'plugin/server','lib/domReady','init'], function (lang, matchClass, matchPanelClass, resultPanelClass, pluginClass, domReady) {
Akron479994e2018-07-02 13:21:44 +020012 domReady(function () {
hebastae094dc62019-12-06 13:12:40 +010013
14 //Load Plugin Server first
Akron8d646d72018-07-08 13:45:53 +020015 KorAP.Plugin = pluginClass.create();
hebastae094dc62019-12-06 13:12:40 +010016
17 //Register result plugin
18 KorAP.Plugin.register({
19 'name' : 'Export',
20 'desc' : 'Exports Kalamar results',
21 // 'about' : 'https://localhost:5678/',
22 'embed' : [{
23 'panel' : 'result',
24 'title' : 'Export',
25 'classes' : ['export'],
26 'onClick' : {
27 'action' : 'addWidget',
28 'template' : 'http://localhost:3003/demo/plugin-client.html',
29 }
30 }]
31 });
Akron7c6e05f2018-07-12 19:08:13 +020032
Akrone1c27f62018-07-20 11:42:59 +020033 // Register match plugin
Akron7c6e05f2018-07-12 19:08:13 +020034 KorAP.Plugin.register({
35 'name' : 'Example New',
36 'desc' : 'Some content about cats',
37 // 'about' : 'https://localhost:5678/',
38 'embed' : [{
Akron10a47962018-07-12 21:17:10 +020039 'panel' : 'match',
Akron7c6e05f2018-07-12 19:08:13 +020040 'title' : 'Translate',
41 'classes' : ['translate'],
42 'onClick' : {
43 'action' : 'addWidget',
Akron7c6e05f2018-07-12 19:08:13 +020044 'template' : 'http://localhost:3003/demo/plugin-client.html',
45 }
46 }]
47 });
Akron479994e2018-07-02 13:21:44 +020048 });
49});