# HG changeset patch # User Alexandre Segura # Date 1487944446 -3600 # Node ID 04500e5914f9cbce41cbb60c7597561cd78edb99 # Parent b38ee6c486ce1832de2b1fbf74e638e2466dc26f Hide comment form when no annotation selected. diff -r b38ee6c486ce -r 04500e5914f9 src/iconolab/templates/iconolab/detail_image.html --- a/src/iconolab/templates/iconolab/detail_image.html Thu Feb 23 20:27:39 2017 +0100 +++ b/src/iconolab/templates/iconolab/detail_image.html Fri Feb 24 14:54:06 2017 +0100 @@ -61,7 +61,7 @@
-
+
@@ -109,7 +109,7 @@ $('.list-group a[data-annotation-id]').removeClass('active'); $el.addClass('active'); - $('#form-comment form').replaceWith(form); + $('#form-comment form').replaceWith(form).show(); vm.annotation = annotations[revision]; @@ -150,7 +150,10 @@ vm.annotation = null; - $('#form-comment form').find('textarea, [type="submit"]').attr('disabled', true); + $('#form-comment form') + .hide() + .find('textarea, [type="submit"]') + .attr('disabled', true); location.hash = ''; });