diff options
author | Mario <mario@mariovavti.com> | 2022-09-22 12:50:11 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2022-09-22 12:50:11 +0000 |
commit | 7cfc14fef755f5d5327f936c042be1b68aef5eaa (patch) | |
tree | d65373ea75a0e28492a26bb2a87848b71c8953a4 | |
parent | f220cf3173118da3ed02e5c7e2f9d36069ba644a (diff) | |
download | volse-hubzilla-7cfc14fef755f5d5327f936c042be1b68aef5eaa.tar.gz volse-hubzilla-7cfc14fef755f5d5327f936c042be1b68aef5eaa.tar.bz2 volse-hubzilla-7cfc14fef755f5d5327f936c042be1b68aef5eaa.zip |
emit a notice if an item was deleted - issue #1691
-rw-r--r-- | include/js_strings.php | 1 | ||||
-rw-r--r-- | view/js/main.js | 2 | ||||
-rw-r--r-- | view/tpl/js_strings.tpl | 1 |
3 files changed, 4 insertions, 0 deletions
diff --git a/include/js_strings.php b/include/js_strings.php index ed73b0420..090d28ce3 100644 --- a/include/js_strings.php +++ b/include/js_strings.php @@ -3,6 +3,7 @@ function js_strings() { return replace_macros(get_markup_template('js_strings.tpl'), array( '$delitem' => t('Delete this item?'), + '$itemdel' => t('Item deleted'), '$comment' => t('Comment'), '$showmore' => sprintf( t('%s show all'), '<i class=\'fa fa-chevron-down\'></i>'), '$showfewer' => sprintf( t('%s show less'), '<i class=\'fa fa-chevron-up\'></i>'), diff --git a/view/js/main.js b/view/js/main.js index b4b440a27..d3eca2681 100644 --- a/view/js/main.js +++ b/view/js/main.js @@ -1284,6 +1284,8 @@ function dropItem(url, object, b64mid) { $(object + ', #pinned-wrapper-' + id).remove(); $('body').css('cursor', 'auto'); + $.jGrowl(aStr.itemdel, { sticky: false, theme: 'notice', life: 3000 }); + if (typeof b64mid !== typeof undefined) { $('[data-b64mid=\'' + b64mid + '\']').fadeOut(function() { this.remove(); diff --git a/view/tpl/js_strings.tpl b/view/tpl/js_strings.tpl index 8f05165f1..46536a89a 100644 --- a/view/tpl/js_strings.tpl +++ b/view/tpl/js_strings.tpl @@ -3,6 +3,7 @@ var aStr = { 'delitem' : "{{$delitem}}", + 'itemdel' : "{{$itemdel}}", 'comment' : "{{$comment}}", 'showmore' : "{{$showmore}}", 'showfewer' : "{{$showfewer}}", |