summaryrefslogtreecommitdiff
path: root/src/runtime/javascript/minibar/minibar_online.js
blob: 1c15e87bf3e1f28259c467d236524830b9f49368 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// minibar_demo.js, assumes that minibar.js and pgf_online.js have been loaded.

var online_options={
  //grammars_url: "http://www.grammaticalframework.org/grammars/",
  //grammars_url: "http://tournesol.cs.chalmers.se:41296/grammars/",
  //grammars_url: "http://localhost:41296/grammars/",
  //grammar_list: ["Foods.pgf"], // leave undefined to get list from server
}


if(/^\?\/tmp\//.test(location.search)) {
  online_options.grammars_url=location.search.substr(1);
}

var server=pgf_online(online_options);

var minibar_options= {
  show_abstract: true,
  show_trees: true,
  show_grouped_translations: false,
  default_source_language: "Eng",
//feedback_url: "feedback.html",
  try_google: true
}
var minibar=new Minibar(server,minibar_options);