diff options
author | zotlabs <mike@macgirvin.com> | 2019-05-03 00:00:00 -0700 |
---|---|---|
committer | zotlabs <mike@macgirvin.com> | 2019-05-03 00:00:00 -0700 |
commit | b1dec1289340385df3699db9e2fe84fe1e37cae5 (patch) | |
tree | 1cd70a41107dcb69537e8d028e8dae3377435278 /view/js/main.js | |
parent | 319b0acdd81851340b332c10aa29d437897ccde7 (diff) | |
parent | c605c46f83b6dc5141f2506ba4b0047b299c26de (diff) | |
download | volse-hubzilla-b1dec1289340385df3699db9e2fe84fe1e37cae5.tar.gz volse-hubzilla-b1dec1289340385df3699db9e2fe84fe1e37cae5.tar.bz2 volse-hubzilla-b1dec1289340385df3699db9e2fe84fe1e37cae5.zip |
Merge branch 'dev' of https://framagit.org/hubzilla/core into dev
Diffstat (limited to 'view/js/main.js')
-rw-r--r-- | view/js/main.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/view/js/main.js b/view/js/main.js index 1322c2112..b99fc0586 100644 --- a/view/js/main.js +++ b/view/js/main.js @@ -231,6 +231,10 @@ function handle_comment_form(e) { $('#' + emptyCommentElm).removeAttr('tabindex'); $('#' + emptySubmitElm).removeAttr('tabindex'); form.find(':not(.comment-edit-text)').hide(); + form.find(':input[name=parent]').val(emptyCommentElm.replace(/\D/g,'')); + var btn = form.find(':button[type=submit]').html(); + form.find(':button[type=submit]').html(btn.replace(/<[^>]*>/g, '').trim()); + form.find(':button[type=submit]').prop('title', ''); } }); @@ -1144,6 +1148,16 @@ function doprofilelike(ident, verb) { $.get('like/' + ident + '?verb=' + verb, function() { window.location.href=window.location.href; }); } +function doreply(parent, ident, owner, hint) { + var form = $('#comment-edit-form-' + parent.toString()); + form.find('input[name=parent]').val(ident); + var i = form.find('button[type=submit]'); + var btn = i.html().replace(/<[^>]*>/g, '').trim(); + i.html('<i class="fa fa-reply" ></i> ' + btn); + i.prop('title', hint); + form.find('textarea').val("@{" + owner + "} "); + $('#comment-edit-text-' + parent.toString()).focus(); +} function dropItem(url, object) { |