diff --git a/src/.meteor/packages b/src/.meteor/packages index f175a69..667e8f9 100644 --- a/src/.meteor/packages +++ b/src/.meteor/packages @@ -56,3 +56,4 @@ alexwine:bootstrap-4 teamon:tinymce tomi:upload-jquery@=2.2.3 tomi:upload-server +chrismbeckett:toastr diff --git a/src/.meteor/versions b/src/.meteor/versions index cdcca43..f16869f 100644 --- a/src/.meteor/versions +++ b/src/.meteor/versions @@ -20,6 +20,7 @@ callback-hook@1.0.4 cfs:graphicsmagick@0.0.18 cfs:http-methods@0.0.32 check@1.1.0 +chrismbeckett:toastr@2.1.2_1 chuangbo:cookie@1.1.0 coffeescript@1.0.11 copleykj:jquery-autosize@1.17.8 diff --git a/src/client/templates/space/home/home.html b/src/client/templates/space/home/home.html index 2a5f406..725e697 100644 --- a/src/client/templates/space/home/home.html +++ b/src/client/templates/space/home/home.html @@ -8,12 +8,14 @@ {{/if}}
{{_ 'home--title'}}
{{#unless space.permissions.public}} - {{#if codePanel}} - + {{#if ownSpace}} + {{#if codePanel}} + + {{/if}} {{/if}} {{/unless}} {{#each homePosts}} diff --git a/src/client/templates/space/home/home_post_submit.js b/src/client/templates/space/home/home_post_submit.js index c69085c..4551180 100644 --- a/src/client/templates/space/home/home_post_submit.js +++ b/src/client/templates/space/home/home_post_submit.js @@ -1,3 +1,11 @@ +Template.homePostSubmit.onCreated(function() { + + toastr.options = { + "positionClass": "toast-bottom-center", + } +}); + + Template.homePostSubmit.events({ 'submit form': function(e, template) { @@ -16,6 +24,7 @@ Template.homePostSubmit.events({ tinymce.activeEditor.setContent(''); // Remove textarea content $(e.target).find('[name=title]').val(''); $('#homePostSubmit').modal('hide'); + toastr.success("",TAPi18n.__('home-post-submit--confirm-toast')); }; }); }, diff --git a/src/client/templates/space/lessons/lessons_post_submit.js b/src/client/templates/space/lessons/lessons_post_submit.js index 1bc12f0..2ed64ef 100644 --- a/src/client/templates/space/lessons/lessons_post_submit.js +++ b/src/client/templates/space/lessons/lessons_post_submit.js @@ -7,6 +7,10 @@ Template.lessonsPostSubmit.onCreated(function() { delete Session.keys["fileExt"]; // Clear fileExt session imageExtensions = ["jpg","jpeg","png","gif"]; + + toastr.options = { + "positionClass": "toast-bottom-center", + } }); @@ -85,6 +89,7 @@ Template.lessonsPostSubmit.events({ $('.lessons-post-submit--button-submit').prop('disabled', true); $('#lessonsPostSubmit').modal('hide'); + toastr.success("",TAPi18n.__('lessons-post-submit--confirm-toast')); }; }); }, diff --git a/src/client/templates/space/live_feed/live_feed_category_edit.html b/src/client/templates/space/live_feed/live_feed_category_edit.html index 8301812..1a212b2 100644 --- a/src/client/templates/space/live_feed/live_feed_category_edit.html +++ b/src/client/templates/space/live_feed/live_feed_category_edit.html @@ -11,7 +11,7 @@