Commit 66cc5c75004955ff41cfe86d30f2b2985f4d0698
- Diff rendering mode:
- inline
- side by side
static/text-annotation.js
(6 / 1)
  | |||
51 | 51 | backdrop: false, | |
52 | 52 | }); | |
53 | 53 | $('.well a').click(function(event){ | |
54 | xpath = $(event.currentTarget).text().split('#')[1]; | ||
54 | if($(event.currentTarget).text().search('#')){ | ||
55 | len = $(event.currentTarget).text().split('#').len(); | ||
56 | xpath = $(event.currentTarget).text().split('#')[len-1]; | ||
57 | } | ||
58 | else | ||
59 | xpath = $(event.currentTarget).text(); | ||
55 | 60 | var nodes = document.evaluate(xpath, document, null, XPathResult.ANY_TYPE,null); | |
56 | 61 | result = nodes.iterateNext(); | |
57 | 62 | while(result){ |