# HG changeset patch # User Mads Kiilerich # Date 1592489316 -7200 # Node ID 6f1e2514495874db492397a6563bcc015d1a0c86 # Parent ff8651b2f14fd9823070a04df1fb55983733e5e7 diff: fix "Show inline comments" jQuery has weak "friendly" semantics for data attributes and do for example interpret the data attribute name 'id_for' as 'idFor'. We could thus not retrieve it as 'id_for'. Instead, avoid the special semantics of '_' by just naming the data attribute 'for'. diff -r ff8651b2f14f -r 6f1e25144958 kallithea/templates/changeset/diff_block.html --- a/kallithea/templates/changeset/diff_block.html Fri Jun 19 18:24:38 2020 +0200 +++ b/kallithea/templates/changeset/diff_block.html Thu Jun 18 16:08:36 2020 +0200 @@ -70,7 +70,7 @@
${_('Show inline comments')} - ${h.checkbox('checkbox-show-inline-' + id_fid, checked="checked",class_="show-inline-comments",**{'data-id_for':id_fid})} + ${h.checkbox('checkbox-show-inline-' + id_fid, checked="checked",class_="show-inline-comments",**{'data-for':id_fid})}
@@ -137,7 +137,7 @@ if(target == null){ target = this; } - var boxid = $(target).data('id_for'); + var boxid = $(target).data('for'); if(target.checked){ $('#{0} .inline-comments'.format(boxid)).show(); }else{