Commit 1346208625d47994465491ee3d8f71525ff054a5
1 parent
a3d4de95
Zmiany w wyświetlaniu jednostek leksykalnych podczas tworzenia/zmiany -- pogrubi…
…enie przy przypisanych przykładach
Showing
1 changed file
with
20 additions
and
2 deletions
semantics/static/js/semantics_lexical_units.js
... | ... | @@ -183,6 +183,7 @@ function getMeaningsSelection() { |
183 | 183 | |
184 | 184 | var i; |
185 | 185 | for (i = 0; i < lexical_units.length; i++) { |
186 | + var hasExamples = hasExample(lexical_units[i].id); | |
186 | 187 | display += "<input type = \"checkbox\" name = \"meaning\" value = \"" + lexical_units[i].id + "\"" |
187 | 188 | var j; |
188 | 189 | for (j = 0; j < lexical_units_num.length; j++) { |
... | ... | @@ -190,7 +191,15 @@ function getMeaningsSelection() { |
190 | 191 | display += " disabled = \"True\"" |
191 | 192 | } |
192 | 193 | } |
193 | - display += ">" + lexical_units[i].base + "-" + lexical_units[i].sense + "<br><div id=\"glossa_" + lexical_units[i].id + "\">" + lexical_units[i].glossa + "</div>" | |
194 | + display += ">"; | |
195 | + if (hasExamples) { | |
196 | + display += "<b>"; | |
197 | + } | |
198 | + display += lexical_units[i].base + "-" + lexical_units[i].sense; | |
199 | + if (hasExamples) { | |
200 | + display += "</b>"; | |
201 | + } | |
202 | + display += "<br><div id=\"glossa_" + lexical_units[i].id + "\">" + lexical_units[i].glossa + "</div>" | |
194 | 203 | } |
195 | 204 | |
196 | 205 | return display; |
... | ... | @@ -206,6 +215,7 @@ function getMeaningsSelectionForFrame(frame_id) { |
206 | 215 | display += "<div>"; |
207 | 216 | var i; |
208 | 217 | for (i = 0; i < lexical_units.length; i++) { |
218 | + var hasExamples = hasExample(lexical_units[i].id); | |
209 | 219 | display += "<input type = \"checkbox\" name = \"meaning\" value = \"" + lexical_units[i].id + "\"" |
210 | 220 | var j; |
211 | 221 | for (j = 0; j < lexical_units_num.length; j++) { |
... | ... | @@ -218,7 +228,15 @@ function getMeaningsSelectionForFrame(frame_id) { |
218 | 228 | } |
219 | 229 | } |
220 | 230 | } |
221 | - display += ">" + lexical_units[i].base + "-" + lexical_units[i].sense + "<br><div id=\"glossa_" + lexical_units[i].id + "\">" + lexical_units[i].glossa + "</div>" | |
231 | + display += ">"; | |
232 | + if (hasExamples) { | |
233 | + display += "<b>"; | |
234 | + } | |
235 | + display += lexical_units[i].base + "-" + lexical_units[i].sense; | |
236 | + if (hasExamples) { | |
237 | + display += "</b>"; | |
238 | + } | |
239 | + display += "<br><div id=\"glossa_" + lexical_units[i].id + "\">" + lexical_units[i].glossa + "</div>" | |
222 | 240 | } |
223 | 241 | display += "</div>"; |
224 | 242 | |
... | ... |