v1.18.x
barisusakli 10 years ago
parent 0bfc568ac3
commit a1c407acd0

@ -10,7 +10,7 @@ define('admin/manage/flags', [
var Flags = {}; var Flags = {};
Flags.init = function() { Flags.init = function() {
$('.post-container .content img').addClass('img-responsive'); $('.post-container .content img:not(.not-responsive)').addClass('img-responsive');
var params = utils.params(); var params = utils.params();
$('#flag-sort-by').val(params.sortBy); $('#flag-sort-by').val(params.sortBy);
@ -91,7 +91,7 @@ define('admin/manage/flags', [
infinitescroll.parseAndTranslate('admin/manage/flags', 'posts', {posts: data.posts}, function(html) { infinitescroll.parseAndTranslate('admin/manage/flags', 'posts', {posts: data.posts}, function(html) {
$('[data-next]').attr('data-next', data.next); $('[data-next]').attr('data-next', data.next);
$('.post-container').append(html); $('.post-container').append(html);
html.find('img').addClass('img-responsive'); html.find('img:not(.not-responsive)').addClass('img-responsive');
done(); done();
}); });
} else { } else {

@ -8,7 +8,7 @@ define('forum/account/favourites', ['forum/account/header', 'forum/account/posts
Favourites.init = function() { Favourites.init = function() {
header.init(); header.init();
$('[component="post/content"] img').addClass('img-responsive'); $('[component="post/content"] img:not(.not-responsive)').addClass('img-responsive');
posts.handleInfiniteScroll('posts.loadMoreFavourites', 'account/favourites'); posts.handleInfiniteScroll('posts.loadMoreFavourites', 'account/favourites');
}; };

@ -9,7 +9,7 @@ define('forum/account/posts', ['forum/account/header', 'forum/infinitescroll'],
AccountPosts.init = function() { AccountPosts.init = function() {
header.init(); header.init();
$('[component="post/content"] img').addClass('img-responsive'); $('[component="post/content"] img:not(.not-responsive)').addClass('img-responsive');
AccountPosts.handleInfiniteScroll('posts.loadMoreUserPosts', 'account/posts'); AccountPosts.handleInfiniteScroll('posts.loadMoreUserPosts', 'account/posts');
}; };
@ -43,7 +43,7 @@ define('forum/account/posts', ['forum/account/header', 'forum/infinitescroll'],
function onPostsLoaded(posts, callback) { function onPostsLoaded(posts, callback) {
infinitescroll.parseAndTranslate(template, 'posts', {posts: posts}, function(html) { infinitescroll.parseAndTranslate(template, 'posts', {posts: posts}, function(html) {
$('[component="posts"]').append(html); $('[component="posts"]').append(html);
html.find('img').addClass('img-responsive'); html.find('img:not(.not-responsive)').addClass('img-responsive');
html.find('.timeago').timeago(); html.find('.timeago').timeago();
app.createUserTooltips(); app.createUserTooltips();
utils.makeNumbersHumanReadable(html.find('.human-readable-number')); utils.makeNumbersHumanReadable(html.find('.human-readable-number'));

@ -44,7 +44,7 @@ define('forum/account/profile', ['forum/account/header', 'forum/infinitescroll',
}; };
function processPage() { function processPage() {
$('[component="posts"] img, [component="aboutme"] img').addClass('img-responsive'); $('[component="posts"] img:not(.not-responsive), [component="aboutme"] img:not(.not-responsive)').addClass('img-responsive');
} }
function updateButtons() { function updateButtons() {

@ -62,7 +62,7 @@ define('forum/categories', ['components', 'translator'], function(components, tr
templates.parse('categories', 'posts', {categories: {posts: posts}}, function(html) { templates.parse('categories', 'posts', {categories: {posts: posts}}, function(html) {
translator.translate(html, function(translatedHTML) { translator.translate(html, function(translatedHTML) {
translatedHTML = $(translatedHTML); translatedHTML = $(translatedHTML);
translatedHTML.find('img').addClass('img-responsive'); translatedHTML.find('img:not(.not-responsive)').addClass('img-responsive');
translatedHTML.find('.timeago').timeago(); translatedHTML.find('.timeago').timeago();
callback(translatedHTML); callback(translatedHTML);
}); });

@ -130,7 +130,7 @@ define('forum/chats', ['components', 'string', 'sounds', 'forum/infinitescroll',
chatContainer = $('.chat-content'); chatContainer = $('.chat-content');
newMessage.appendTo(chatContainer); newMessage.appendTo(chatContainer);
newMessage.find('.timeago').timeago(); newMessage.find('.timeago').timeago();
newMessage.find('img:not(".chat-user-image")').addClass('img-responsive'); newMessage.find('img:not(.not-responsive)').addClass('img-responsive');
Chats.scrollToBottom($('.expanded-chat .chat-content')); Chats.scrollToBottom($('.expanded-chat .chat-content'));
} }

@ -24,7 +24,7 @@ define('forum/groups/details', ['iconSelect', 'components', 'forum/infinitescrol
handleMemberInfiniteScroll(); handleMemberInfiniteScroll();
handleMemberInvitations(); handleMemberInvitations();
components.get('groups/activity').find('.content img').addClass('img-responsive'); components.get('groups/activity').find('.content img:not(.not-responsive)').addClass('img-responsive');
detailsPage.on('click', '[data-action]', function() { detailsPage.on('click', '[data-action]', function() {
var btnEl = $(this), var btnEl = $(this),

@ -125,7 +125,7 @@ define('forum/search', ['search', 'autocomplete'], function(searchModule, autoco
var result = $(this); var result = $(this);
var text = result.html().replace(regex, '<strong>$1</strong>'); var text = result.html().replace(regex, '<strong>$1</strong>');
result.html(text).find('img').addClass('img-responsive').each(function() { result.html(text).find('img:not(.not-responsive)').addClass('img-responsive').each(function() {
$(this).attr('src', $(this).attr('src').replace(/<strong>([\s\S]*?)<\/strong>/gi, '$1')); $(this).attr('src', $(this).attr('src').replace(/<strong>([\s\S]*?)<\/strong>/gi, '$1'));
}); });

@ -110,7 +110,7 @@ define('forum/topic/events', [
editedPostEl.fadeOut(250, function() { editedPostEl.fadeOut(250, function() {
editedPostEl.html(data.post.content); editedPostEl.html(data.post.content);
editedPostEl.find('img').addClass('img-responsive'); editedPostEl.find('img:not(.not-responsive)').addClass('img-responsive');
app.replaceSelfLinks(editedPostEl.find('a')); app.replaceSelfLinks(editedPostEl.find('a'));
editedPostEl.fadeIn(250); editedPostEl.fadeIn(250);
}); });

@ -471,7 +471,7 @@ define('chat', ['components', 'taskbar', 'string', 'sounds', 'forum/chats', 'tra
Chats.parseMessage(data, function(html) { Chats.parseMessage(data, function(html) {
var message = $(html); var message = $(html);
message.find('img:not(".chat-user-image")').addClass('img-responsive'); message.find('img:not(.not-responsive)').addClass('img-responsive');
message.find('.timeago').timeago(); message.find('.timeago').timeago();
message.appendTo(chatContent); message.appendTo(chatContent);
Chats.scrollToBottom(chatContent); Chats.scrollToBottom(chatContent);

@ -74,7 +74,7 @@
} }
var widgetAreas = $('#content [widget-area]'); var widgetAreas = $('#content [widget-area]');
widgetAreas.find('img:not(.user-img)').addClass('img-responsive'); widgetAreas.find('img:not(.not-responsive)').addClass('img-responsive');
widgetAreas.find('.timeago').timeago(); widgetAreas.find('.timeago').timeago();
widgetAreas.find('img[title].teaser-pic,img[title].user-img').each(function() { widgetAreas.find('img[title].teaser-pic,img[title].user-img').each(function() {
$(this).tooltip({ $(this).tooltip({

Loading…
Cancel
Save