aboutsummaryrefslogtreecommitdiffstats
path: root/web/templates/index.html
diff options
context:
space:
mode:
authorGuillaume Horel <guillaume.horel@gmail.com>2014-07-29 18:50:09 -0400
committerGuillaume Horel <guillaume.horel@gmail.com>2014-07-29 18:50:09 -0400
commit2ab5da4bfdce9f41e93a27082900da6ea72db6ed (patch)
treebdbe27d77fea5f77e0b6a8934ab01391f03a8057 /web/templates/index.html
parentdfcd65c8f10aa94f19fe40940565681ab9a73e44 (diff)
downloadocr-layer-curation-2ab5da4bfdce9f41e93a27082900da6ea72db6ed.tar.gz
Webapp now show three columns
image, original text and corrected text. The highlighting is functional as well.
Diffstat (limited to 'web/templates/index.html')
-rw-r--r--web/templates/index.html31
1 files changed, 21 insertions, 10 deletions
diff --git a/web/templates/index.html b/web/templates/index.html
index b3b5fe0..2ba18c1 100644
--- a/web/templates/index.html
+++ b/web/templates/index.html
@@ -1,14 +1,25 @@
{% extends "layout.html" %}
{% block main %}
- <div id="image_container">
- <img id="page" src="{{page_number}}.jpg" usemap="#wordmap" />
- </div>
- <map name="wordmap">{% for id, coords in areas %}
- <area href="#" shape="rect" coords="{{coords}}" data-id="{{id}}" />{% end %}
- </map>
- <div id="text">
- {% for id, word in words %}
- <span id="{{id}}">{{word}}</span> {% end %}
- </div>
+<div id="image_container">
+ <img id="page" src="{{page_number}}.jpg" usemap="#wordmap" />
+</div>
+<map name="wordmap">
+ {% for i, coord in enumerate(orig_coords) %}
+ <area href="#" shape="rect" coords="{{coord}}" data-id="{{i}}" />
+ {% end %}
+</map>
+
+<div id="texte-non-corrige">
+ <h3>Texte original</h3>
+ {% for i, word in enumerate(orig_words) %}
+ <span id="orig-{{i}}">{{word}}</span>
+ {% end %}
+</div>
+<div id="texte-corrige">
+ <h3>Texte corrigé</h3>
+ {% for i, word in enumerate(corr_words) %}
+ <span id="corr-{{corr_coords_index[i]}}">{{word}}</span>
+ {% end %}
+</div>
{% end %}