mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-03 12:36:02 +01:00
Merge commit 'f2152953cddd3247746ef393516b0a53ba7750a4' into v3.x
This commit is contained in:
29
CHANGELOG.md
29
CHANGELOG.md
@@ -1,3 +1,32 @@
|
|||||||
|
#### v3.2.1 (2023-07-05)
|
||||||
|
|
||||||
|
##### Chores
|
||||||
|
|
||||||
|
* up harmony (9fc5ae08)
|
||||||
|
* up composer (82d37702)
|
||||||
|
* up spider-detector (97d8f858)
|
||||||
|
* incrementing version number - v3.2.0 (9ecac38e)
|
||||||
|
* update changelog for v3.2.0 (080f9e75)
|
||||||
|
* incrementing version number - v3.1.7 (0b4e81ab)
|
||||||
|
* incrementing version number - v3.1.6 (b3a3b130)
|
||||||
|
* incrementing version number - v3.1.5 (ec19343a)
|
||||||
|
* incrementing version number - v3.1.4 (2452783c)
|
||||||
|
* incrementing version number - v3.1.3 (3b4e9d3f)
|
||||||
|
* incrementing version number - v3.1.2 (40fa3489)
|
||||||
|
* incrementing version number - v3.1.1 (40250733)
|
||||||
|
* incrementing version number - v3.1.0 (0cb386bd)
|
||||||
|
* incrementing version number - v3.0.1 (26f6ea49)
|
||||||
|
* incrementing version number - v3.0.0 (224e08cd)
|
||||||
|
|
||||||
|
##### Bug Fixes
|
||||||
|
|
||||||
|
* #11766, allow privileged users to vote and chat (1bda9073)
|
||||||
|
* #11775, trim -rtl from targetSkin (0183e5f8)
|
||||||
|
* #11773, fix create token button (64d30182)
|
||||||
|
* add ?page= to canonical urls (4045681a)
|
||||||
|
* group membership methods for guests/spiders (7d5fe20b)
|
||||||
|
* **deps:** update dependency nodebb-plugin-emoji to v5.1.3 (#11777) (a1110f10)
|
||||||
|
|
||||||
#### v3.2.0 (2023-06-28)
|
#### v3.2.0 (2023-06-28)
|
||||||
|
|
||||||
##### Chores
|
##### Chores
|
||||||
|
|||||||
@@ -99,12 +99,12 @@
|
|||||||
"nodebb-plugin-markdown": "12.1.4",
|
"nodebb-plugin-markdown": "12.1.4",
|
||||||
"nodebb-plugin-mentions": "4.2.0",
|
"nodebb-plugin-mentions": "4.2.0",
|
||||||
"nodebb-plugin-ntfy": "1.0.15",
|
"nodebb-plugin-ntfy": "1.0.15",
|
||||||
"nodebb-plugin-spam-be-gone": "2.1.0",
|
"nodebb-plugin-spam-be-gone": "2.1.1",
|
||||||
"nodebb-rewards-essentials": "0.2.3",
|
"nodebb-rewards-essentials": "0.2.3",
|
||||||
"nodebb-theme-harmony": "1.0.65",
|
"nodebb-theme-harmony": "1.0.66",
|
||||||
"nodebb-theme-lavender": "7.1.1",
|
"nodebb-theme-lavender": "7.1.1",
|
||||||
"nodebb-theme-peace": "2.0.32",
|
"nodebb-theme-peace": "2.0.32",
|
||||||
"nodebb-theme-persona": "13.1.6",
|
"nodebb-theme-persona": "13.1.8",
|
||||||
"nodebb-widget-essentials": "7.0.13",
|
"nodebb-widget-essentials": "7.0.13",
|
||||||
"nodemailer": "6.9.3",
|
"nodemailer": "6.9.3",
|
||||||
"nprogress": "0.2.0",
|
"nprogress": "0.2.0",
|
||||||
|
|||||||
@@ -68,6 +68,8 @@ CommonProps:
|
|||||||
type: string
|
type: string
|
||||||
as:
|
as:
|
||||||
type: string
|
type: string
|
||||||
|
noEscape:
|
||||||
|
type: boolean
|
||||||
crossorigin:
|
crossorigin:
|
||||||
type: string
|
type: string
|
||||||
enum: ['', 'anonymous', 'use-credentials']
|
enum: ['', 'anonymous', 'use-credentials']
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
#nprogress {
|
#nprogress {
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
#nprogress .bar {
|
#nprogress .bar {
|
||||||
background: #29d;
|
background: #29d;
|
||||||
|
|
||||||
position: fixed;
|
position: fixed;
|
||||||
@@ -12,9 +12,9 @@
|
|||||||
|
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 2px;
|
height: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#nprogress .peg {
|
#nprogress .peg {
|
||||||
display: block;
|
display: block;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 0px;
|
right: 0px;
|
||||||
@@ -26,26 +26,13 @@
|
|||||||
-webkit-transform: rotate(3deg) translate(0px, -4px);
|
-webkit-transform: rotate(3deg) translate(0px, -4px);
|
||||||
-ms-transform: rotate(3deg) translate(0px, -4px);
|
-ms-transform: rotate(3deg) translate(0px, -4px);
|
||||||
transform: rotate(3deg) translate(0px, -4px);
|
transform: rotate(3deg) translate(0px, -4px);
|
||||||
}
|
}
|
||||||
|
|
||||||
#nprogress .spinner {
|
#nprogress .spinner {
|
||||||
display: block;
|
display: none;
|
||||||
position: fixed;
|
}
|
||||||
z-index: 1031;
|
|
||||||
top: 165px;
|
|
||||||
right: 35px;
|
|
||||||
}
|
|
||||||
|
|
||||||
@include media-breakpoint-down(sm) {
|
#nprogress .spinner-icon {
|
||||||
#nprogress .spinner {
|
|
||||||
bottom: 15px;
|
|
||||||
right: 15px;
|
|
||||||
top: initial;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#nprogress .spinner-icon {
|
|
||||||
width: 18px;
|
width: 18px;
|
||||||
height: 18px;
|
height: 18px;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
@@ -57,24 +44,24 @@
|
|||||||
|
|
||||||
-webkit-animation: nprogress-spinner 400ms linear infinite;
|
-webkit-animation: nprogress-spinner 400ms linear infinite;
|
||||||
animation: nprogress-spinner 400ms linear infinite;
|
animation: nprogress-spinner 400ms linear infinite;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nprogress-custom-parent {
|
.nprogress-custom-parent {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nprogress-custom-parent #nprogress .spinner,
|
.nprogress-custom-parent #nprogress .spinner,
|
||||||
.nprogress-custom-parent #nprogress .bar {
|
.nprogress-custom-parent #nprogress .bar {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
}
|
}
|
||||||
|
|
||||||
@-webkit-keyframes nprogress-spinner {
|
@-webkit-keyframes nprogress-spinner {
|
||||||
0% { -webkit-transform: rotate(0deg); }
|
0% { -webkit-transform: rotate(0deg); }
|
||||||
100% { -webkit-transform: rotate(360deg); }
|
100% { -webkit-transform: rotate(360deg); }
|
||||||
}
|
}
|
||||||
@keyframes nprogress-spinner {
|
@keyframes nprogress-spinner {
|
||||||
0% { transform: rotate(0deg); }
|
0% { transform: rotate(0deg); }
|
||||||
100% { transform: rotate(360deg); }
|
100% { transform: rotate(360deg); }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -46,20 +46,20 @@ define('admin/appearance/themes', ['bootbox', 'translator', 'alerts'], function
|
|||||||
});
|
});
|
||||||
|
|
||||||
$('#revert_theme').on('click', function () {
|
$('#revert_theme').on('click', function () {
|
||||||
if (config['theme:id'] === 'nodebb-theme-persona') {
|
if (config['theme:id'] === 'nodebb-theme-harmony') {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
bootbox.confirm('[[admin/appearance/themes:revert-confirm]]', function (confirm) {
|
bootbox.confirm('[[admin/appearance/themes:revert-confirm]]', function (confirm) {
|
||||||
if (confirm) {
|
if (confirm) {
|
||||||
socket.emit('admin.themes.set', {
|
socket.emit('admin.themes.set', {
|
||||||
type: 'local',
|
type: 'local',
|
||||||
id: 'nodebb-theme-persona',
|
id: 'nodebb-theme-harmony',
|
||||||
}, function (err) {
|
}, function (err) {
|
||||||
if (err) {
|
if (err) {
|
||||||
return alerts.error(err);
|
return alerts.error(err);
|
||||||
}
|
}
|
||||||
config['theme:id'] = 'nodebb-theme-persona';
|
config['theme:id'] = 'nodebb-theme-harmony';
|
||||||
highlightSelectedTheme('nodebb-theme-persona');
|
highlightSelectedTheme('nodebb-theme-harmony');
|
||||||
alerts.alert({
|
alerts.alert({
|
||||||
alert_id: 'admin:theme',
|
alert_id: 'admin:theme',
|
||||||
type: 'success',
|
type: 'success',
|
||||||
|
|||||||
@@ -342,7 +342,7 @@ define('admin/extend/plugins', [
|
|||||||
|
|
||||||
function populateUpgradeablePlugins() {
|
function populateUpgradeablePlugins() {
|
||||||
$('#installed ul li').each(function () {
|
$('#installed ul li').each(function () {
|
||||||
if ($(this).children('[data-action="upgrade"]').length) {
|
if ($(this).find('[data-action="upgrade"]').length) {
|
||||||
$('#upgrade ul').append($(this).clone(true));
|
$('#upgrade ul').append($(this).clone(true));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -110,7 +110,6 @@ define('forum/post-queue', [
|
|||||||
if (listEl) {
|
if (listEl) {
|
||||||
listEl.addEventListener('click', (e) => {
|
listEl.addEventListener('click', (e) => {
|
||||||
const subselector = e.target.closest('[data-action]');
|
const subselector = e.target.closest('[data-action]');
|
||||||
console.log(subselector);
|
|
||||||
if (subselector) {
|
if (subselector) {
|
||||||
const action = subselector.getAttribute('data-action');
|
const action = subselector.getAttribute('data-action');
|
||||||
const uid = subselector.closest('[data-uid]').getAttribute('data-uid');
|
const uid = subselector.closest('[data-uid]').getAttribute('data-uid');
|
||||||
|
|||||||
@@ -327,11 +327,11 @@ module.exports = function (utils, Benchpress, relative_path) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function generateRepliedTo(post, timeagoCutoff) {
|
function generateRepliedTo(post, timeagoCutoff) {
|
||||||
const username = post.parent && post.parent.username ?
|
const displayname = post.parent && post.parent.displayname ?
|
||||||
post.parent.username : '[[global:guest]]';
|
post.parent.displayname : '[[global:guest]]';
|
||||||
const isBeforeCutoff = post.timestamp < (Date.now() - (timeagoCutoff * oneDayInMs));
|
const isBeforeCutoff = post.timestamp < (Date.now() - (timeagoCutoff * oneDayInMs));
|
||||||
const langSuffix = isBeforeCutoff ? 'on' : 'ago';
|
const langSuffix = isBeforeCutoff ? 'on' : 'ago';
|
||||||
return `[[topic:replied-to-user-${langSuffix}, ${post.toPid}, ${relative_path}/post/${post.toPid}, ${username}, ${relative_path}/post/${post.pid}, ${post.timestampISO}]]`;
|
return `[[topic:replied-to-user-${langSuffix}, ${post.toPid}, ${relative_path}/post/${post.toPid}, ${displayname}, ${relative_path}/post/${post.pid}, ${post.timestampISO}]]`;
|
||||||
}
|
}
|
||||||
|
|
||||||
function generateWrote(post, timeagoCutoff) {
|
function generateWrote(post, timeagoCutoff) {
|
||||||
|
|||||||
@@ -261,6 +261,7 @@ async function addTags(topicData, req, res, currentPage) {
|
|||||||
{
|
{
|
||||||
rel: 'canonical',
|
rel: 'canonical',
|
||||||
href: `${url}/topic/${topicData.slug}${page}`,
|
href: `${url}/topic/${topicData.slug}${page}`,
|
||||||
|
noEscape: true,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -65,7 +65,7 @@ helpers.buildBodyClass = function (req, res, templateData = {}) {
|
|||||||
|
|
||||||
parts.push(`page-status-${res.statusCode}`);
|
parts.push(`page-status-${res.statusCode}`);
|
||||||
|
|
||||||
parts.push(`theme-${meta.config['theme:id'].split('-')[2]}`);
|
parts.push(`theme-${(meta.config['theme:id'] || '').split('-')[2]}`);
|
||||||
|
|
||||||
if (req.loggedIn) {
|
if (req.loggedIn) {
|
||||||
parts.push('user-loggedin');
|
parts.push('user-loggedin');
|
||||||
|
|||||||
@@ -186,13 +186,13 @@ module.exports = function (Topics) {
|
|||||||
const parentUids = _.uniq(parentPosts.map(postObj => postObj && postObj.uid));
|
const parentUids = _.uniq(parentPosts.map(postObj => postObj && postObj.uid));
|
||||||
const userData = await user.getUsersFields(parentUids, ['username']);
|
const userData = await user.getUsersFields(parentUids, ['username']);
|
||||||
|
|
||||||
const usersMap = {};
|
const usersMap = _.zipObject(parentUids, userData);
|
||||||
userData.forEach((user) => {
|
|
||||||
usersMap[user.uid] = user.username;
|
|
||||||
});
|
|
||||||
const parents = {};
|
const parents = {};
|
||||||
parentPosts.forEach((post, i) => {
|
parentPosts.forEach((post, i) => {
|
||||||
parents[parentPids[i]] = { username: usersMap[post.uid] };
|
parents[parentPids[i]] = {
|
||||||
|
username: usersMap[post.uid].username,
|
||||||
|
displayname: usersMap[post.uid].displayname,
|
||||||
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
postData.forEach((post) => {
|
postData.forEach((post) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user