diff --git a/public/src/forum/admin/settings.js b/public/src/forum/admin/settings.js index acb74827f4..95cc3c1b9b 100644 --- a/public/src/forum/admin/settings.js +++ b/public/src/forum/admin/settings.js @@ -89,6 +89,12 @@ define(['uploader'], function(uploader) { uploader.hideAlerts(); }); + + $('#settings-tab a').click(function (e) { + e.preventDefault(); + $(this).tab('show'); + return false; + }); }; Settings.remove = function(key) { diff --git a/public/src/forum/footer.js b/public/src/forum/footer.js index c10d951088..5c1d57b51e 100644 --- a/public/src/forum/footer.js +++ b/public/src/forum/footer.js @@ -250,18 +250,9 @@ }); function updateUnreadCount(count) { - var badge = $('#numUnreadBadge'); - badge.html(count > 20 ? '20+' : count); - if (count > 0) { - badge - .removeClass('badge-inverse') - .addClass('badge-important'); - } else { - badge - .removeClass('badge-important') - .addClass('badge-inverse'); - } + $('#unread-count').toggleClass('unread-count', count > 0); + $('#unread-count').attr('data-content', count > 20 ? '20+' : count); } socket.on('event:unread.updateCount', updateUnreadCount); diff --git a/public/src/forum/topic.js b/public/src/forum/topic.js index bfd423fedc..799451d60a 100644 --- a/public/src/forum/topic.js +++ b/public/src/forum/topic.js @@ -996,13 +996,13 @@ define(['composer'], function(composer) { return; } - var container = $(document.body), + var container = $(window), scrollTo = $('#post_anchor_' + pid), tid = $('#post-container').attr('data-tid'); function animateScroll() { - $('body,html').animate({ - scrollTop: scrollTo.offset().top - container.offset().top + container.scrollTop() - $('#header-menu').height() + $('window,html').animate({ + scrollTop: scrollTo.offset().top + container.scrollTop() - $('#header-menu').height() }, 400); } diff --git a/public/src/modules/chat.js b/public/src/modules/chat.js index 990b86b8fc..32d5e6ee8c 100644 --- a/public/src/modules/chat.js +++ b/public/src/modules/chat.js @@ -58,6 +58,7 @@ define(['taskbar', 'string'], function(taskbar, S) { chatModal.attr('id', 'chat-modal-' + touid); chatModal.attr('UUID', uuid); + chatModal.css("position", "fixed"); chatModal.appendTo($('body')); chatModal.draggable({ start:function() { @@ -96,9 +97,10 @@ define(['taskbar', 'string'], function(taskbar, S) { } module.center = function(chatModal) { - chatModal.css("position", "fixed"); chatModal.css("left", Math.max(0, (($(window).width() - $(chatModal).outerWidth()) / 2) + $(window).scrollLeft()) + "px"); chatModal.css("top", "0px"); + chatModal.css("zIndex", 2000); + chatModal.find('#chat-message-input').focus(); return chatModal; } @@ -109,7 +111,7 @@ define(['taskbar', 'string'], function(taskbar, S) { checkOnlineStatus(chatModal); taskbar.updateActive(uuid); scrollToBottom(chatModal.find('#chat-content')); - chatModal.find('#chat-message-input').focus(); + module.center(chatModal); } module.minimize = function(uuid) { @@ -163,9 +165,11 @@ define(['taskbar', 'string'], function(taskbar, S) { }; function scrollToBottom(chatContent) { - chatContent.scrollTop( - chatContent[0].scrollHeight - chatContent.height() - ); + if(chatContent[0]) { + chatContent.scrollTop( + chatContent[0].scrollHeight - chatContent.height() + ); + } } module.toggleNew = function(uuid, state) { diff --git a/public/templates/admin/settings.tpl b/public/templates/admin/settings.tpl index b5fef202c8..8ddd896da9 100644 --- a/public/templates/admin/settings.tpl +++ b/public/templates/admin/settings.tpl @@ -1,137 +1,148 @@

Settings


-

General Settings

-
-
- -
- -
- -
- -
-
- -
- -
-
-
-
-
+ + +
+
+
+
+ +
+ +
+ +
+ +
+

+ +
+
+
+
+
+
+
+ +
+
+
+

Use privilege thresholds to manage how much reputation a user must gain to receive moderator access.


+ Manage Thread

+ Manage Content

+
+ +
+
+
+
+
+
+
+
+

+ Please ensure that you have installed a third-party emailer (e.g. PostageApp, Mailgun, Mandrill, SendGrid, etc), otherwise emails will not be sent by NodeBB +

+

+ Email Address
+ The following email address refers to the email that the recipient will see in the "From" and "Reply To" fields. +

+
+
+
+
+
+ +
+
+
+
+ +
+
+ +
+
+ +
+ +
+ Minimum Username Length
+
+ Maximum Username Length
+
+ Minimum Password Length
+
+ Maximum Signature Length
+
+
+
+
+ +
+
+
+ Post Delay

+ Minimum Title Length

+ Maximum Title Length

+ Minimum Post Length

+ Chat Messages To Display

+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+ Maximum File Size

+
+
+
+ +
+
+
+ Custom Robots.txt Leave blank for default
+ +
+
+
-
-

Privilege Thresholds

-
-

Use privilege thresholds to manage how much reputation a user must gain to receive moderator access.


- Manage Thread

- Manage Content

-
- -
-
-
- -
-

Email Settings

-
-
-

- Please ensure that you have installed a third-party emailer (e.g. PostageApp, Mailgun, Mandrill, SendGrid, etc), otherwise emails will not be sent by NodeBB -

-

- Email Address
- The following email address refers to the email that the recipient will see in the "From" and "Reply To" fields. -

-
-
-
-
- -
-

Profile Settings

-
-
- -
-
-
- -
-

User Settings

-
-
- -
-
- -
- Minimum Username Length
-
- Maximum Username Length
-
- Minimum Password Length
-
- Maximum Signature Length
-
-
-
- -
-

Post Settings

-
- Post Delay

- Minimum Title Length

- Maximum Title Length

- Minimum Post Length

- Chat Messages To Display

-
- -
-
- -
-
- -
-
- -
-
- -
- Maximum File Size

-
-
- -
-

Web Crawler Settings

-
- Custom Robots.txt Leave blank for default
- -
-
diff --git a/public/templates/header.tpl b/public/templates/header.tpl index cf8bc888a7..e5c5bad73a 100644 --- a/public/templates/header.tpl +++ b/public/templates/header.tpl @@ -58,7 +58,7 @@
  • - 0 +