From 0713475dc5ecb045d099381904b2db9cb27201e3 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Fri, 3 Sep 2021 15:04:06 +0000 Subject: [PATCH 001/412] chore: update changelog for v1.18.1 --- CHANGELOG.md | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index de31b7fb97..466a49bd4a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,47 @@ +#### v1.18.1 (2021-09-03) + +##### Chores + +* found some hooks that don't play well docgen (ae793b4a) +* incrementing version number - v1.18.0 (1e436ae7) +* update changelog for v1.18.0 (2fd9c095) +* **deps:** update dependency mocha to v9.1.1 (64bac178) + +##### New Features + +* create folders in ACP uploads #9638 (#9750) (3df79683) +* column based view on wide priv. tables (#9699) (61f02f17) +* als (#9749) (e59d3575) +* add quick reply key (e9314842) +* add new lang key for no best posts (6e73d8c9) + +##### Bug Fixes + +* **deps:** + * update dependency autoprefixer to v10.3.4 (67b932f4) + * update dependency nodebb-theme-persona to v11.2.4 (fe18e100) + * update dependency mongodb to v3.7.0 (31a35d7f) + * update socket.io packages to v4.2.0 (f2028d70) + * update dependency ioredis to v4.27.9 (6052eb16) + * update dependency mongodb to v3.6.12 (#9761) (5fa982c1) + * update dependency nodebb-plugin-composer-default to v7.0.2 (33d51201) + * update dependency nodebb-theme-slick to v1.4.12 (1b416d7e) + * update dependency nodebb-theme-slick to v1.4.11 (65b32fa1) + * update dependency nodebb-theme-persona to v11.2.3 (6ce321e4) + * update dependency autoprefixer to v10.3.3 (91ba7cdf) + * update dependency nodebb-theme-slick to v1.4.9 (d80b378f) + * update dependency jquery-deserialize to v2.0.0 (#9744) (7f9451ce) +* determine indeterminate checkboxes (760ea9df) +* move app.alert back into the conditionals (ca9bae3a) +* only show email confirmation warning toast on pages that it applies (1bd1cc74) +* updated email confirm warning to be more positive (2d1380dd) +* automated tests are a good thing to have (6afeac37) + +##### Refactors + +* consistent jquery element var naming (fc0e655e) +* var to const (1272da65) + #### v1.18.0 (2021-08-25) ##### Breaking Changes From f8f80e4fb3f5677af80de00e848c6227896cbaa2 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Fri, 3 Sep 2021 15:04:06 +0000 Subject: [PATCH 002/412] chore: incrementing version number - v1.18.1 (cherry picked from commit 0409403f5b122fbf4221491cf3c81ff76fa0e4b1) Signed-off-by: Misty (Bot) --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 3e837e7f90..345e5e1add 100644 --- a/install/package.json +++ b/install/package.json @@ -2,7 +2,7 @@ "name": "nodebb", "license": "GPL-3.0", "description": "NodeBB Forum", - "version": "1.18.0", + "version": "1.18.1", "homepage": "http://www.nodebb.org", "repository": { "type": "git", From 6869920e06e0f92b3a1a662be400f79d377d331d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 11:22:42 -0400 Subject: [PATCH 003/412] fix: #9773, fire hooks properly for priv changes (#9774) --- src/api/categories.js | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/src/api/categories.js b/src/api/categories.js index 3486df1ad5..f2b3a830b6 100644 --- a/src/api/categories.js +++ b/src/api/categories.js @@ -65,10 +65,20 @@ categoriesAPI.setPrivilege = async (caller, data) => { if (!userExists && !groupExists) { throw new Error('[[error:no-user-or-group]]'); } - - await privileges.categories[data.set ? 'give' : 'rescind']( - Array.isArray(data.privilege) ? data.privilege : [data.privilege], data.cid, data.member - ); + const privs = Array.isArray(data.privilege) ? data.privilege : [data.privilege]; + const type = data.set ? 'give' : 'rescind'; + if (!privs.length) { + throw new Error('[[error:invalid-data]]'); + } + let privMethod = privileges.categories[type]; + if (parseInt(data.cid, 10) === 0) { + if (privs[0].startsWith('admin:')) { + privMethod = privileges.admin[type]; + } else { + privMethod = privileges.global[type]; + } + } + await privMethod(privs, data.cid, data.member); await events.log({ uid: caller.uid, From 46e5e17d0fff3c44765f376f298ba5636cde890a Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 11:34:09 -0400 Subject: [PATCH 004/412] fix: focus on save button on plugin activation --- public/src/admin/extend/plugins.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/public/src/admin/extend/plugins.js b/public/src/admin/extend/plugins.js index 064b2fa79e..b51e8e4189 100644 --- a/public/src/admin/extend/plugins.js +++ b/public/src/admin/extend/plugins.js @@ -79,6 +79,12 @@ define('admin/extend/plugins', [ callback: toggleActivate, }, }, + onShown: function () { + const saveEl = this.querySelector('button.btn-primary'); + if (saveEl) { + saveEl.focus(); + } + }, }); }); } else { From 4ac701d7473ec43c79bdb7073e1534c32607b51e Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 11:57:18 -0400 Subject: [PATCH 005/412] fix: deprecate userData.showHidden as it is functionally equivalent to userData.canEdit --- src/controllers/accounts/helpers.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/accounts/helpers.js b/src/controllers/accounts/helpers.js index 359355da87..7628347dda 100644 --- a/src/controllers/accounts/helpers.js +++ b/src/controllers/accounts/helpers.js @@ -78,7 +78,7 @@ helpers.getUserDataByUserSlug = async function (userslug, callerUID, query = {}) userData.isSelf = isSelf; userData.isFollowing = results.isFollowing; userData.hasPrivateChat = results.hasPrivateChat; - userData.showHidden = isSelf || isAdmin || (isGlobalModerator && !results.isTargetAdmin); + userData.showHidden = results.canEdit; // remove in v1.19.0 userData.groups = Array.isArray(results.groups) && results.groups.length ? results.groups[0] : []; userData.disableSignatures = meta.config.disableSignatures === 1; userData['reputation:disabled'] = meta.config['reputation:disabled'] === 1; From 1f91a3132795b51a63ba124dbe2985b48c669f7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 11:58:17 -0400 Subject: [PATCH 006/412] Priv hook fix (#9775) * fix: #9773, fire hooks properly for priv changes * fix: admin/global group privs dont allow invalid privs --- src/api/categories.js | 16 ++++++++++------ src/privileges/admin.js | 2 ++ src/privileges/global.js | 2 ++ 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/src/api/categories.js b/src/api/categories.js index f2b3a830b6..118dd0a258 100644 --- a/src/api/categories.js +++ b/src/api/categories.js @@ -70,15 +70,19 @@ categoriesAPI.setPrivilege = async (caller, data) => { if (!privs.length) { throw new Error('[[error:invalid-data]]'); } - let privMethod = privileges.categories[type]; if (parseInt(data.cid, 10) === 0) { - if (privs[0].startsWith('admin:')) { - privMethod = privileges.admin[type]; - } else { - privMethod = privileges.global[type]; + const adminPrivs = privs.filter(priv => privileges.admin.privilegeList.includes(priv)); + const globalPrivs = privs.filter(priv => privileges.global.privilegeList.includes(priv)); + if (adminPrivs.length) { + await privileges.admin[type](adminPrivs, data.member); } + if (globalPrivs.length) { + await privileges.global[type](globalPrivs, data.member); + } + } else { + const categoryPrivs = privs.filter(priv => privileges.categories.privilegeList.includes(priv)); + await privileges.categories[type](categoryPrivs, data.cid, data.member); } - await privMethod(privs, data.cid, data.member); await events.log({ uid: caller.uid, diff --git a/src/privileges/admin.js b/src/privileges/admin.js index ead7f6fc5e..d98e2c2bca 100644 --- a/src/privileges/admin.js +++ b/src/privileges/admin.js @@ -35,6 +35,8 @@ privsAdmin.userPrivilegeList = [ privsAdmin.groupPrivilegeList = privsAdmin.userPrivilegeList.map(privilege => `groups:${privilege}`); +privsAdmin.privilegeList = privsAdmin.userPrivilegeList.concat(privsAdmin.groupPrivilegeList); + // Mapping for a page route (via direct match or regexp) to a privilege privsAdmin.routeMap = { dashboard: 'admin:dashboard', diff --git a/src/privileges/global.js b/src/privileges/global.js index 563ae3d053..206e7769c3 100644 --- a/src/privileges/global.js +++ b/src/privileges/global.js @@ -49,6 +49,8 @@ privsGlobal.userPrivilegeList = [ privsGlobal.groupPrivilegeList = privsGlobal.userPrivilegeList.map(privilege => `groups:${privilege}`); +privsGlobal.privilegeList = privsGlobal.userPrivilegeList.concat(privsGlobal.groupPrivilegeList); + privsGlobal.list = async function () { async function getLabels() { return await utils.promiseParallel({ From dd4e66e22c93586d389b47fa197154620508ae8f Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 12:04:16 -0400 Subject: [PATCH 007/412] fix: push back some deprecations, remove deprecated stuff scheduled for v1.18.0 --- src/emailer.js | 2 +- src/middleware/user.js | 4 ++-- src/plugins/hooks.js | 2 +- src/plugins/index.js | 17 ----------------- src/privileges/index.js | 17 ----------------- 5 files changed, 4 insertions(+), 38 deletions(-) diff --git a/src/emailer.js b/src/emailer.js index 0d6e309b0a..754b794c05 100644 --- a/src/emailer.js +++ b/src/emailer.js @@ -324,7 +324,7 @@ Emailer.sendToEmail = async (template, email, language, params) => { !Plugins.hooks.hasListeners('static:email.send'); try { if (Plugins.hooks.hasListeners('filter:email.send')) { - // Deprecated, remove in v1.18.0 + // Deprecated, remove in v1.19.0 await Plugins.hooks.fire('filter:email.send', data); } else if (Plugins.hooks.hasListeners('static:email.send')) { await Plugins.hooks.fire('static:email.send', data); diff --git a/src/middleware/user.js b/src/middleware/user.js index 4adff804d5..b9f195477e 100644 --- a/src/middleware/user.js +++ b/src/middleware/user.js @@ -82,7 +82,7 @@ module.exports = function (middleware) { return !res.headersSent; } - // TODO: Remove in v1.18.0 + // TODO: Remove in v1.19.0 middleware.authenticate = helpers.try(async (req, res, next) => { winston.warn(`[middleware] middleware.authenticate has been deprecated, page and API routes are now automatically authenticated via setup(Page|API)Route. Use middleware.authenticateRequest (if not using route helper) and middleware.ensureLoggedIn instead. (request path: ${req.path})`); if (!await authenticate(req, res)) { @@ -101,7 +101,7 @@ module.exports = function (middleware) { next(); }); - // TODO: Remove in v1.18.0 + // TODO: Remove in v1.19.0 middleware.authenticateOrGuest = (req, res, next) => { winston.warn(`[middleware] middleware.authenticateOrGuest has been renamed, use middleware.authenticateRequest instead. (request path: ${req.path})`); middleware.authenticateRequest(req, res, next); diff --git a/src/plugins/hooks.js b/src/plugins/hooks.js index d46a1fcdb0..24875ca986 100644 --- a/src/plugins/hooks.js +++ b/src/plugins/hooks.js @@ -8,7 +8,7 @@ const utils = require('../utils'); const Hooks = module.exports; Hooks.deprecatedHooks = { - 'filter:email.send': 'static:email.send', // 👋 @ 1.18.0 + 'filter:email.send': 'static:email.send', // 👋 @ 1.19.0 'filter:router.page': 'response:router.page', // 👋 @ 2.0.0 }; diff --git a/src/plugins/index.js b/src/plugins/index.js index a7e8560dd5..772ec91e19 100644 --- a/src/plugins/index.js +++ b/src/plugins/index.js @@ -25,23 +25,6 @@ require('./usage')(Plugins); Plugins.data = require('./data'); Plugins.hooks = require('./hooks'); -// Backwards compatibility for hooks, remove in v1.18.0 -const _deprecate = async function (...args) { - const oldMethod = args.shift(); - const newMethod = args.shift(); - const method = args.shift(); - const stack = new Error().stack.toString().split(os.EOL); - const context = stack[stack.findIndex(line => line.startsWith(' at Object.wrapperCallback')) + 1]; - winston.warn(`[plugins/hooks] ${oldMethod} has been deprecated, call ${newMethod} instead.`); - winston.warn(`[plugins/hooks] ${context}`); - return method.apply(Plugins.hooks, args); -}; -Plugins.registerHook = _deprecate.bind(null, 'Plugins.registerHook', 'Plugins.hooks.register', Plugins.hooks.register); -Plugins.unregisterHook = _deprecate.bind(null, 'Plugins.unregisterHook', 'Plugins.hooks.unregister', Plugins.hooks.unregister); -Plugins.fireHook = _deprecate.bind(null, 'Plugins.fireHook', 'Plugins.hooks.fire', Plugins.hooks.fire); -Plugins.hasListeners = _deprecate.bind(null, 'Plugins.hasListeners', 'Plugins.hooks.hasListeners', Plugins.hooks.hasListeners); -// end - Plugins.getPluginPaths = Plugins.data.getPluginPaths; Plugins.loadPluginInfo = Plugins.data.loadPluginInfo; diff --git a/src/privileges/index.js b/src/privileges/index.js index 4a9c4d2096..6445b07b97 100644 --- a/src/privileges/index.js +++ b/src/privileges/index.js @@ -9,20 +9,3 @@ privileges.posts = require('./posts'); privileges.users = require('./users'); require('../promisify')(privileges); - -// TODO: backwards compatibility remove in 1.18.0 -[ - 'privilegeLabels', - 'userPrivilegeList', - 'groupPrivilegeList', - 'privilegeList', -].forEach((fieldName) => { - Object.defineProperty(privileges, fieldName, { - configurable: true, - enumerable: true, - get: function () { - console.warn(`[deprecated] privileges.${fieldName} is deprecated. Use privileges.categories.${fieldName}`); - return privileges.categories[fieldName]; - }, - }); -}); From 72710b804062e26460bd0195510523a876b51c3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 12:22:03 -0400 Subject: [PATCH 008/412] fix: #9772, regression from https://github.com/NodeBB/NodeBB/commit/70a04bc10577e90e28d66a647d38cafc3307a285 --- src/controllers/authentication.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/authentication.js b/src/controllers/authentication.js index 132c0b33f7..875976a635 100644 --- a/src/controllers/authentication.js +++ b/src/controllers/authentication.js @@ -200,7 +200,7 @@ authenticationController.registerComplete = function (req, res, next) { return winston.warn('[register] Interstitial callbacks processed with no errors, but one or more interstitials remain. This is likely an issue with one of the interstitials not properly handling a null case or invalid value.'); } - done(); + done(null, data); } else { // Update user hash, clear registration data in session const payload = req.session.registration; From 488f0978a4aa1ca1e4d2a1f2e8c7ef7a681f2f27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 12:29:11 -0400 Subject: [PATCH 009/412] fix: manifest error --- src/meta/tags.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/meta/tags.js b/src/meta/tags.js index daa4d4808c..1f2c68e13f 100644 --- a/src/meta/tags.js +++ b/src/meta/tags.js @@ -66,6 +66,7 @@ Tags.parse = async (req, data, meta, link) => { }, { rel: 'manifest', href: `${relative_path}/manifest.webmanifest`, + crossorigin: `use-credentials`, }]; if (plugins.hooks.hasListeners('filter:search.query')) { From 1e2bda13d0891dbd9b115ee57fa826fb89dc26a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 12:41:11 -0400 Subject: [PATCH 010/412] fix: lint --- src/plugins/index.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/plugins/index.js b/src/plugins/index.js index 772ec91e19..04675f1a45 100644 --- a/src/plugins/index.js +++ b/src/plugins/index.js @@ -1,7 +1,6 @@ 'use strict'; const fs = require('fs'); -const os = require('os'); const path = require('path'); const winston = require('winston'); const semver = require('semver'); From 60de0844754fd9102027e013db0375429a6054f1 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 13:36:56 -0400 Subject: [PATCH 011/412] fix: simplify logic for fullname and email blanking in user retrieval (getUserDataByUserSlug) Previous logic seemed to match the logic used in privileges.users.canEdit, except the latter allows plugins to modify the value. --- src/controllers/accounts/helpers.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/controllers/accounts/helpers.js b/src/controllers/accounts/helpers.js index 7628347dda..c3a4cb6d35 100644 --- a/src/controllers/accounts/helpers.js +++ b/src/controllers/accounts/helpers.js @@ -43,13 +43,13 @@ helpers.getUserDataByUserSlug = async function (userslug, callerUID, query = {}) userData.emailClass = 'hide'; - if (!isAdmin && !isGlobalModerator && !isSelf && (!userSettings.showemail || meta.config.hideEmail)) { + if (!results.canEdit && (!userSettings.showemail || meta.config.hideEmail)) { userData.email = ''; } else if (!userSettings.showemail) { userData.emailClass = ''; } - if (!isAdmin && !isGlobalModerator && !isSelf && (!userSettings.showfullname || meta.config.hideFullname)) { + if (!results.canEdit && (!userSettings.showfullname || meta.config.hideFullname)) { userData.fullname = ''; } From 57e54d559beece183cbce3b6cc7c7657d0ea17ad Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Fri, 3 Sep 2021 17:57:43 +0000 Subject: [PATCH 012/412] fix(deps): update dependency nodebb-theme-persona to v11.2.5 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 345e5e1add..de02ca25a2 100644 --- a/install/package.json +++ b/install/package.json @@ -93,7 +93,7 @@ "nodebb-plugin-spam-be-gone": "0.7.9", "nodebb-rewards-essentials": "0.1.5", "nodebb-theme-lavender": "5.2.1", - "nodebb-theme-persona": "11.2.4", + "nodebb-theme-persona": "11.2.5", "nodebb-theme-slick": "1.4.12", "nodebb-theme-vanilla": "12.1.2", "nodebb-widget-essentials": "5.0.4", From a48bbdbfe38d9b802389d1b75f1cdc2045eacdac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 15:30:05 -0400 Subject: [PATCH 013/412] fix: errors from registerComplete --- src/controllers/authentication.js | 33 ++++++++++++++----------------- 1 file changed, 15 insertions(+), 18 deletions(-) diff --git a/src/controllers/authentication.js b/src/controllers/authentication.js index 875976a635..4340b16508 100644 --- a/src/controllers/authentication.js +++ b/src/controllers/authentication.js @@ -138,16 +138,14 @@ async function addToApprovalQueue(req, userData) { return { message: message }; } -authenticationController.registerComplete = function (req, res, next) { - // For the interstitials that respond, execute the callback with the form body - plugins.hooks.fire('filter:register.interstitial', { - req, - userData: req.session.registration, - interstitials: [], - }, async (err, data) => { - if (err) { - return next(err); - } +authenticationController.registerComplete = async function (req, res) { + try { + // For the interstitials that respond, execute the callback with the form body + const data = await plugins.hooks.fire('filter:register.interstitial', { + req, + userData: req.session.registration, + interstitials: [], + }); const callbacks = data.interstitials.reduce((memo, cur) => { if (cur.hasOwnProperty('callback') && typeof cur.callback === 'function') { @@ -165,13 +163,10 @@ authenticationController.registerComplete = function (req, res, next) { return memo; }, []); - const done = function (err, data) { + const done = function (data) { delete req.session.registration; - if (err) { - return res.redirect(`${nconf.get('relative_path')}/?register=${encodeURIComponent(err.message)}`); - } - if (!err && data && data.message) { + if (data && data.message) { return res.redirect(`${nconf.get('relative_path')}/?register=${encodeURIComponent(data.message)}`); } @@ -199,8 +194,7 @@ authenticationController.registerComplete = function (req, res, next) { if (!data) { return winston.warn('[register] Interstitial callbacks processed with no errors, but one or more interstitials remain. This is likely an issue with one of the interstitials not properly handling a null case or invalid value.'); } - - done(null, data); + done(data); } else { // Update user hash, clear registration data in session const payload = req.session.registration; @@ -217,7 +211,10 @@ authenticationController.registerComplete = function (req, res, next) { await user.setUserFields(uid, payload); done(); } - }); + } catch (err) { + delete req.session.registration; + res.redirect(`${nconf.get('relative_path')}/?register=${encodeURIComponent(err.message)}`); + } }; authenticationController.registerAbort = function (req, res) { From e33e046f1547848883085896f0fc6df2e9d178a6 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 15:24:50 -0400 Subject: [PATCH 014/412] fix: use privileges.users.canEdit for image upload priv check --- src/socket.io/user/profile.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/socket.io/user/profile.js b/src/socket.io/user/profile.js index 4f757943ac..2de4160ba5 100644 --- a/src/socket.io/user/profile.js +++ b/src/socket.io/user/profile.js @@ -6,6 +6,7 @@ const api = require('../../api'); const user = require('../../user'); const events = require('../../events'); const notifications = require('../../notifications'); +const privileges = require('../../privileges'); const db = require('../../database'); const plugins = require('../../plugins'); const sockets = require('..'); @@ -31,10 +32,10 @@ module.exports = function (SocketUser) { }; SocketUser.uploadCroppedPicture = async function (socket, data) { - if (!socket.uid) { + if (!socket.uid || !(await privileges.users.canEdit(socket.uid, data.uid))) { throw new Error('[[error:no-privileges]]'); } - await user.isAdminOrGlobalModOrSelf(socket.uid, data.uid); + await user.checkMinReputation(socket.uid, data.uid, 'min:rep:profile-picture'); data.callerUid = socket.uid; return await user.uploadCroppedPicture(data); From 0a41741b7e135c07ac360f6e44910a8a0133e3b7 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 15:25:26 -0400 Subject: [PATCH 015/412] refactor: deprecate picture update socket call, new API routes for picture update --- public/openapi/write.yaml | 2 + public/openapi/write/users/uid/picture.yaml | 43 +++++++++++++++++++++ public/src/modules/accounts/picture.js | 19 +++------ src/api/users.js | 41 ++++++++++++++++++++ src/controllers/write/users.js | 5 +++ src/routes/write/users.js | 1 + src/socket.io/user/picture.js | 39 +++---------------- 7 files changed, 103 insertions(+), 47 deletions(-) create mode 100644 public/openapi/write/users/uid/picture.yaml diff --git a/public/openapi/write.yaml b/public/openapi/write.yaml index 8ac39fe982..734b64ff24 100644 --- a/public/openapi/write.yaml +++ b/public/openapi/write.yaml @@ -52,6 +52,8 @@ paths: $ref: 'write/users.yaml' /users/{uid}: $ref: 'write/users/uid.yaml' + /users/{uid}/picture: + $ref: 'write/users/uid/picture.yaml' /users/{uid}/content: $ref: 'write/users/uid/content.yaml' /users/{uid}/account: diff --git a/public/openapi/write/users/uid/picture.yaml b/public/openapi/write/users/uid/picture.yaml new file mode 100644 index 0000000000..d6498a0af2 --- /dev/null +++ b/public/openapi/write/users/uid/picture.yaml @@ -0,0 +1,43 @@ +put: + tags: + - users + summary: update user picture or icon background colour + parameters: + - in: path + name: uid + schema: + type: integer + required: true + description: uid of the user + example: 1 + requestBody: + content: + application/json: + schema: + type: object + properties: + type: + type: string + description: The source of the picture + enum: ['default', 'uploaded', 'external'] + example: default + url: + type: string + description: Only used for `external` type, specifies the source of the external image to use as avatar + example: '' + bgColor: + type: string + description: A hexadecimal colour representation + example: '#ff0000' + responses: + '200': + description: successfully updated user picture + content: + application/json: + schema: + type: object + properties: + status: + $ref: ../../../components/schemas/Status.yaml#/Status + response: + type: object \ No newline at end of file diff --git a/public/src/modules/accounts/picture.js b/public/src/modules/accounts/picture.js index a97e0fb891..3893f2e27a 100644 --- a/public/src/modules/accounts/picture.js +++ b/public/src/modules/accounts/picture.js @@ -2,7 +2,8 @@ define('accounts/picture', [ 'pictureCropper', -], (pictureCropper) => { + 'api', +], (pictureCropper, api) => { const Picture = {}; Picture.openChangeModal = () => { @@ -89,14 +90,10 @@ define('accounts/picture', [ var type = modal.find('.list-group-item.active').attr('data-type'); const iconBgColor = document.querySelector('.modal.picture-switcher input[type="radio"]:checked').value || 'transparent'; - changeUserPicture(type, iconBgColor, function (err) { - if (err) { - return app.alertError(err.message); - } - + changeUserPicture(type, iconBgColor).then(() => { Picture.updateHeader(type === 'default' ? '' : modal.find('.list-group-item.active img').attr('src'), iconBgColor); ajaxify.refresh(); - }); + }).catch(app.alertError); } function onCloseModal() { @@ -212,12 +209,8 @@ define('accounts/picture', [ }); } - function changeUserPicture(type, bgColor, callback) { - socket.emit('user.changePicture', { - type, - bgColor, - uid: ajaxify.data.theirid, - }, callback); + function changeUserPicture(type, bgColor) { + return api.put(`/users/${ajaxify.data.theirid}/picture`, { type, bgColor }); } return Picture; diff --git a/src/api/users.js b/src/api/users.js index b7deaed080..71d3a0c8f4 100644 --- a/src/api/users.js +++ b/src/api/users.js @@ -341,3 +341,44 @@ usersAPI.search = async function (caller, data) { filters: filters, }); }; + +usersAPI.changePicture = async (caller, data) => { + if (!data) { + throw new Error('[[error:invalid-data]]'); + } + + const { type, url } = data; + let picture = ''; + + await user.checkMinReputation(caller.uid, data.uid, 'min:rep:profile-picture'); + const canEdit = await privileges.users.canEdit(caller.uid, data.uid); + if (!canEdit) { + throw new Error('[[error:no-privileges]]'); + } + + if (type === 'default') { + picture = ''; + } else if (type === 'uploaded') { + picture = await user.getUserField(data.uid, 'uploadedpicture'); + } else if (type === 'external' && url) { + picture = validator.escape(url); + } else { + const returnData = await plugins.hooks.fire('filter:user.getPicture', { + uid: caller.uid, + type: type, + picture: undefined, + }); + picture = returnData && returnData.picture; + } + + const validBackgrounds = await user.getIconBackgrounds(caller.uid); + if (!validBackgrounds.includes(data.bgColor)) { + data.bgColor = validBackgrounds[0]; + } + + await user.updateProfile(caller.uid, { + uid: data.uid, + picture: picture, + 'icon:bgColor': data.bgColor, + }, ['picture', 'icon:bgColor']); +}; diff --git a/src/controllers/write/users.js b/src/controllers/write/users.js index 43aa2c0ccc..2469ae4b2a 100644 --- a/src/controllers/write/users.js +++ b/src/controllers/write/users.js @@ -76,6 +76,11 @@ Users.deleteMany = async (req, res) => { helpers.formatApiResponse(200, res); }; +Users.changePicture = async (req, res) => { + await api.users.changePicture(req, { ...req.body, uid: req.params.uid }); + helpers.formatApiResponse(200, res); +}; + Users.updateSettings = async (req, res) => { const settings = await api.users.updateSettings(req, { ...req.body, uid: req.params.uid }); helpers.formatApiResponse(200, res, settings); diff --git a/src/routes/write/users.js b/src/routes/write/users.js index 02a64e134f..418fa9897d 100644 --- a/src/routes/write/users.js +++ b/src/routes/write/users.js @@ -22,6 +22,7 @@ function authenticatedRoutes() { setupApiRoute(router, 'get', '/:uid', [...middlewares, middleware.assert.user], controllers.write.users.get); setupApiRoute(router, 'put', '/:uid', [...middlewares, middleware.assert.user], controllers.write.users.update); setupApiRoute(router, 'delete', '/:uid', [...middlewares, middleware.assert.user], controllers.write.users.delete); + setupApiRoute(router, 'put', '/:uid/picture', [...middlewares, middleware.assert.user], controllers.write.users.changePicture); setupApiRoute(router, 'delete', '/:uid/content', [...middlewares, middleware.assert.user], controllers.write.users.deleteContent); setupApiRoute(router, 'delete', '/:uid/account', [...middlewares, middleware.assert.user], controllers.write.users.deleteAccount); diff --git a/src/socket.io/user/picture.js b/src/socket.io/user/picture.js index a5a2fbbea7..186ab02835 100644 --- a/src/socket.io/user/picture.js +++ b/src/socket.io/user/picture.js @@ -3,42 +3,13 @@ const user = require('../../user'); const plugins = require('../../plugins'); +const websockets = require('../index'); +const api = require('../../api'); + module.exports = function (SocketUser) { SocketUser.changePicture = async function (socket, data) { - if (!socket.uid) { - throw new Error('[[error:invalid-uid]]'); - } - - if (!data) { - throw new Error('[[error:invalid-data]]'); - } - - const { type } = data; - let picture = ''; - await user.isAdminOrGlobalModOrSelf(socket.uid, data.uid); - if (type === 'default') { - picture = ''; - } else if (type === 'uploaded') { - picture = await user.getUserField(data.uid, 'uploadedpicture'); - } else { - const returnData = await plugins.hooks.fire('filter:user.getPicture', { - uid: socket.uid, - type: type, - picture: undefined, - }); - picture = returnData && returnData.picture; - } - - const validBackgrounds = await user.getIconBackgrounds(socket.uid); - if (!validBackgrounds.includes(data.bgColor)) { - data.bgColor = validBackgrounds[0]; - } - - await user.updateProfile(socket.uid, { - uid: data.uid, - picture: picture, - 'icon:bgColor': data.bgColor, - }, ['picture', 'icon:bgColor']); + websockets.warnDeprecated(socket, 'PUT /api/v3/users/:uid/picture'); + await api.users.changePicture(socket, data); }; SocketUser.removeUploadedPicture = async function (socket, data) { From cdaea61136f05e2f42a7aeb9f999f19e8517b8fb Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 15:53:25 -0400 Subject: [PATCH 016/412] fix: handle missing uid in deprecated socket call --- src/socket.io/user/picture.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/socket.io/user/picture.js b/src/socket.io/user/picture.js index 186ab02835..7de2ef7165 100644 --- a/src/socket.io/user/picture.js +++ b/src/socket.io/user/picture.js @@ -8,6 +8,10 @@ const api = require('../../api'); module.exports = function (SocketUser) { SocketUser.changePicture = async function (socket, data) { + if (!socket.uid) { + throw new Error('[[error:invalid-uid]]'); + } + websockets.warnDeprecated(socket, 'PUT /api/v3/users/:uid/picture'); await api.users.changePicture(socket, data); }; From 8cbad61e8a94f1dedfa308dc83da50d7f30d1879 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 16:46:14 -0400 Subject: [PATCH 017/412] test: added test for external image via new change picture API --- test/helpers/index.js | 10 ++++++++++ test/user.js | 23 +++++++++++++++++++++++ 2 files changed, 33 insertions(+) diff --git a/test/helpers/index.js b/test/helpers/index.js index ecb2ebd0a4..79a0e9e41e 100644 --- a/test/helpers/index.js +++ b/test/helpers/index.js @@ -10,6 +10,16 @@ const utils = require('../../public/src/utils'); const helpers = module.exports; +helpers.getCsrfToken = async (jar) => { + const { csrf_token: token } = await requestAsync({ + url: `${nconf.get('url')}/api/config`, + json: true, + jar, + }); + + return token; +}; + helpers.loginUser = function (username, password, callback) { const jar = request.jar(); diff --git a/test/user.js b/test/user.js index 4c9a61cd86..e74eb8252d 100644 --- a/test/user.js +++ b/test/user.js @@ -5,6 +5,7 @@ const async = require('async'); const fs = require('fs'); const path = require('path'); const nconf = require('nconf'); +const validator = require('validator'); const request = require('request'); const requestAsync = require('request-promise-native'); const jwt = require('jsonwebtoken'); @@ -1070,6 +1071,28 @@ describe('User', () => { }); }); + it('should let you set an external image', async () => { + const token = await helpers.getCsrfToken(jar); + const body = await requestAsync(`${nconf.get('url')}/api/v3/users/${uid}/picture`, { + jar, + method: 'put', + json: true, + headers: { + 'x-csrf-token': token, + }, + body: { + type: 'external', + url: 'https://example.org/picture.jpg', + }, + }); + + assert(body && body.status && body.response); + assert.strictEqual(body.status.code, 'ok'); + + const picture = await User.getUserField(uid, 'picture'); + assert.strictEqual(picture, validator.escape('https://example.org/picture.jpg')); + }); + it('should fail to change user picture with invalid data', (done) => { socketUser.changePicture({ uid: uid }, null, (err) => { assert.equal(err.message, '[[error:invalid-data]]'); From 0b3ea5adb4ed4e302e78ca2305c7f7a5e246e931 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Fri, 3 Sep 2021 21:05:03 +0000 Subject: [PATCH 018/412] fix(deps): update dependency nodebb-theme-vanilla to v12.1.3 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index de02ca25a2..1e2dd6e361 100644 --- a/install/package.json +++ b/install/package.json @@ -95,7 +95,7 @@ "nodebb-theme-lavender": "5.2.1", "nodebb-theme-persona": "11.2.5", "nodebb-theme-slick": "1.4.12", - "nodebb-theme-vanilla": "12.1.2", + "nodebb-theme-vanilla": "12.1.3", "nodebb-widget-essentials": "5.0.4", "nodemailer": "^6.5.0", "nprogress": "0.2.0", From 87ba768f5c5f060b4a3bf2ef9d303425a6f8aae8 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Sun, 15 Aug 2021 11:23:02 +0000 Subject: [PATCH 019/412] chore(deps): update commitlint monorepo to v13 --- install/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index 1e2dd6e361..4cf3e48156 100644 --- a/install/package.json +++ b/install/package.json @@ -142,8 +142,8 @@ }, "devDependencies": { "@apidevtools/swagger-parser": "10.0.3", - "@commitlint/cli": "12.1.4", - "@commitlint/config-angular": "12.1.4", + "@commitlint/cli": "13.1.0", + "@commitlint/config-angular": "13.1.0", "coveralls": "3.1.1", "eslint": "7.32.0", "eslint-config-nodebb": "0.0.2", From 856ba78a5f0c971dfd6d39a20a7d9fe25ceb4ec9 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Sep 2021 17:13:55 -0400 Subject: [PATCH 020/412] fix: replace logic in isPrivilegedOrSelfAndPasswordMatch to use privileges.users.canEdit --- src/api/users.js | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/api/users.js b/src/api/users.js index 71d3a0c8f4..cbd64e7fd5 100644 --- a/src/api/users.js +++ b/src/api/users.js @@ -227,14 +227,9 @@ usersAPI.unban = async function (caller, data) { async function isPrivilegedOrSelfAndPasswordMatch(caller, data) { const { uid } = caller; const isSelf = parseInt(uid, 10) === parseInt(data.uid, 10); + const canEdit = await privileges.users.canEdit(uid, data.uid); - const [isAdmin, isTargetAdmin, isGlobalMod] = await Promise.all([ - user.isAdministrator(uid), - user.isAdministrator(data.uid), - user.isGlobalModerator(uid), - ]); - - if ((isTargetAdmin && !isAdmin) || (!isSelf && !(isAdmin || isGlobalMod))) { + if (!canEdit) { throw new Error('[[error:no-privileges]]'); } const [hasPassword, passwordMatch] = await Promise.all([ From 0ce4b87d856e7021a0d2394fcd60f8081c826ea5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 3 Sep 2021 20:34:42 -0400 Subject: [PATCH 021/412] fix: #9781 (#9782) --- src/database/mongo/hash.js | 18 +++++++++++++++--- src/database/postgres/hash.js | 4 +++- src/database/redis/hash.js | 6 +++++- test/database/hash.js | 35 ++++++++++++++++++++++++++++++++++- 4 files changed, 57 insertions(+), 6 deletions(-) diff --git a/src/database/mongo/hash.js b/src/database/mongo/hash.js index 0829bbf8af..67daab7b16 100644 --- a/src/database/mongo/hash.js +++ b/src/database/mongo/hash.js @@ -14,6 +14,9 @@ module.exports = function (module) { } const writeData = helpers.serializeData(data); + if (!Object.keys(writeData).length) { + return; + } try { if (isArray) { const bulk = module.client.collection('objects').initializeUnorderedBulkOp(); @@ -39,9 +42,18 @@ module.exports = function (module) { const writeData = data.map(helpers.serializeData); try { - const bulk = module.client.collection('objects').initializeUnorderedBulkOp(); - keys.forEach((key, i) => bulk.find({ _key: key }).upsert().updateOne({ $set: writeData[i] })); - await bulk.execute(); + let bulk; + keys.forEach((key, i) => { + if (Object.keys(writeData[i]).length) { + if (!bulk) { + bulk = module.client.collection('objects').initializeUnorderedBulkOp(); + } + bulk.find({ _key: key }).upsert().updateOne({ $set: writeData[i] }); + } + }); + if (bulk) { + await bulk.execute(); + } } catch (err) { if (err && err.message.startsWith('E11000 duplicate key error')) { return await module.setObjectBulk(keys, data); diff --git a/src/database/postgres/hash.js b/src/database/postgres/hash.js index 1a733a3518..04b38713c2 100644 --- a/src/database/postgres/hash.js +++ b/src/database/postgres/hash.js @@ -11,7 +11,9 @@ module.exports = function (module) { if (data.hasOwnProperty('')) { delete data['']; } - + if (!Object.keys(data).length) { + return; + } await module.transaction(async (client) => { const dataString = JSON.stringify(data); async function setOne(key) { diff --git a/src/database/redis/hash.js b/src/database/redis/hash.js index 103cbc4a81..966a36eddd 100644 --- a/src/database/redis/hash.js +++ b/src/database/redis/hash.js @@ -41,7 +41,11 @@ module.exports = function (module) { return; } const batch = module.client.batch(); - keys.forEach((k, i) => batch.hmset(k, data[i])); + keys.forEach((k, i) => { + if (Object.keys(data[i]).length) { + batch.hmset(k, data[i]); + } + }); await helpers.execBatch(batch); cache.del(keys); }; diff --git a/test/database/hash.js b/test/database/hash.js index 39c4e39624..650afae8bf 100644 --- a/test/database/hash.js +++ b/test/database/hash.js @@ -72,7 +72,7 @@ describe('Hash methods', () => { }); }); - it('should set multiple keys to different okjects', async () => { + it('should set multiple keys to different objects', async () => { const keys = ['bulkKey1', 'bulkKey2']; const data = [{ foo: '1' }, { baz: 'baz' }]; @@ -80,6 +80,39 @@ describe('Hash methods', () => { const result = await db.getObjects(keys); assert.deepStrictEqual(result, data); }); + + it('should not error if object is empty', async () => { + const keys = ['bulkKey3', 'bulkKey4']; + const data = [{ foo: '1' }, { }]; + + await db.setObjectBulk(keys, data); + const result = await db.getObjects(keys); + assert.deepStrictEqual(result, [{ foo: '1' }, null]); + }); + + it('should not error if object is empty', async () => { + const keys = ['bulkKey5']; + const data = [{ }]; + + await db.setObjectBulk(keys, data); + const result = await db.getObjects(keys); + assert.deepStrictEqual(result, [null]); + }); + + it('should not error if object is empty', async () => { + const keys = ['bulkKey6', 'bulkKey7']; + const data = {}; + + await db.setObject(keys, data); + const result = await db.getObjects(keys); + assert.deepStrictEqual(result, [null, null]); + }); + + it('should not error if object is empty', async () => { + await db.setObject('emptykey', {}); + const result = await db.getObject('emptykey'); + assert.deepStrictEqual(result, null); + }); }); describe('setObjectField()', () => { From 2e1b99f504d67014a23e47b3573a351808b3dc55 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Sun, 5 Sep 2021 09:06:12 +0000 Subject: [PATCH 022/412] Latest translations and fallbacks --- public/language/fr/admin/manage/uploads.json | 4 ++-- public/language/fr/error.json | 6 +++--- public/language/vi/admin/manage/privileges.json | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/public/language/fr/admin/manage/uploads.json b/public/language/fr/admin/manage/uploads.json index a0a8608e07..8f1e276a6f 100644 --- a/public/language/fr/admin/manage/uploads.json +++ b/public/language/fr/admin/manage/uploads.json @@ -6,6 +6,6 @@ "size/filecount": "Taille / nombre de fichiers", "confirm-delete": "Voulez-vous vraiment supprimer ce fichier?", "filecount": "%1 fichiers", - "new-folder": "New Folder", - "name-new-folder": "Enter a name for new the folder" + "new-folder": "Nouveau Dossier", + "name-new-folder": "Entrez un nom pour le nouveau dossier" } \ No newline at end of file diff --git a/public/language/fr/error.json b/public/language/fr/error.json index 4ee0be6ce4..a3c870ca55 100644 --- a/public/language/fr/error.json +++ b/public/language/fr/error.json @@ -25,14 +25,14 @@ "invalid-event": "Événement non valide: %1", "local-login-disabled": "Le système de connexion local a été désactivé pour les comptes sans privilèges.", "csrf-invalid": "Nous ne pouvons pas vous connectez, probablement car votre session a expiré. Merci de réessayer.", - "invalid-path": "Invalid path", - "folder-exists": "Folder exists", + "invalid-path": "Chemin invalide", + "folder-exists": "Le dossier existe", "invalid-pagination-value": "Valeur de pagination invalide. Celle-ci doit être comprise entre %1 et %2.", "username-taken": "Nom d’utilisateur déjà utilisé", "email-taken": "Email déjà utilisé", "email-nochange": "Le mail saisi est déjà enregistré.", "email-invited": "Cet utilisateur a déjà été invité.", - "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", + "email-not-confirmed": "La publication dans certaines catégories ou sujets sera activée après confirmation de e-mail, veuillez cliquer ici pour envoyer un e-mail de confirmation.", "email-not-confirmed-chat": "Il ne vous est pas possible d'utiliser le chat tant que votre adresse email n'a pas été vérifiée. Veuillez cliquer ici pour confirmer votre adresse email.", "email-not-confirmed-email-sent": "Votre email n'a pas encore été confirmé, veuillez vérifier votre boîte mail. Vous ne pourrez pas poster ou discuter avant que votre email ne soit confirmé.", "no-email-to-confirm": "Votre compte n'a pas d'adresse mail définie. Un mail est nécessaire pour la récupération du compte. Veuillez cliquer ici pour entrer un courriel.", diff --git a/public/language/vi/admin/manage/privileges.json b/public/language/vi/admin/manage/privileges.json index 15ae622bc9..a41a2edd82 100644 --- a/public/language/vi/admin/manage/privileges.json +++ b/public/language/vi/admin/manage/privileges.json @@ -59,5 +59,5 @@ "alert.admin-warning": "Quản trị viên ngầm có tất cả các đặc quyền", "alert.copyPrivilegesFrom-title": "Chọn một danh mục để sao chép từ", "alert.copyPrivilegesFrom-warning": "Điều này sẽ sao chép %1 từ danh mục đã chọn.", - "alert.copyPrivilegesFromGroup-warning": "This will copy this group's set of %1 from the selected category." + "alert.copyPrivilegesFromGroup-warning": "Thao tác này sẽ sao chép cài đặt %1 của nhóm này từ danh mục đã chọn." } \ No newline at end of file From 90845200278c16ebf0a8ff15ada39f95c4fe7f7b Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Mon, 6 Sep 2021 09:06:27 +0000 Subject: [PATCH 023/412] Latest translations and fallbacks --- public/language/it/admin/manage/privileges.json | 14 +++++++------- public/language/it/admin/manage/uploads.json | 4 ++-- public/language/it/error.json | 6 +++--- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/public/language/it/admin/manage/privileges.json b/public/language/it/admin/manage/privileges.json index 032e6a844a..0da351c033 100644 --- a/public/language/it/admin/manage/privileges.json +++ b/public/language/it/admin/manage/privileges.json @@ -51,13 +51,13 @@ "alert.saved": "Modifiche ai privilegi salvate e applicate", "alert.confirm-discard": "Sei sicuro di voler annullare le modifiche ai privilegi?", "alert.discarded": "Modifiche ai privilegi ignorate", - "alert.confirm-copyToAll": "Are you sure you wish to apply this set of %1 to all categories?", - "alert.confirm-copyToAllGroup": "Are you sure you wish to apply this group's set of %1 to all categories?", - "alert.confirm-copyToChildren": "Are you sure you wish to apply this set of %1 to all descendant (child) categories?", - "alert.confirm-copyToChildrenGroup": "Are you sure you wish to apply this group's set of %1 to all descendant (child) categories?", + "alert.confirm-copyToAll": "Sei sicuro di voler applicare questa serie di %1 a tutte le categorie?", + "alert.confirm-copyToAllGroup": "Sei sicuro di voler applicare questa serie di %1 del gruppo a tutte le categorie?", + "alert.confirm-copyToChildren": "Sei sicuro di voler applicare questa serie di %1 a tutte le categorie discendenti (figli)?", + "alert.confirm-copyToChildrenGroup": "Sei sicuro di voler applicare questa serie di %1 del questo gruppo a tutte le categorie discendenti (figli)?", "alert.no-undo": "Questa azione non può essere annullata.", "alert.admin-warning": "Gli amministratori ottengono implicitamente tutti i privilegi", - "alert.copyPrivilegesFrom-title": "Select a category to copy from", - "alert.copyPrivilegesFrom-warning": "This will copy %1 from the selected category.", - "alert.copyPrivilegesFromGroup-warning": "This will copy this group's set of %1 from the selected category." + "alert.copyPrivilegesFrom-title": "Seleziona una categoria da cui copiare", + "alert.copyPrivilegesFrom-warning": "Questo copierà 1% dalla categoria selezionata.", + "alert.copyPrivilegesFromGroup-warning": "Questo copierà la serie di %1 da questo gruppo dalla categoria selezionata." } \ No newline at end of file diff --git a/public/language/it/admin/manage/uploads.json b/public/language/it/admin/manage/uploads.json index 7d12c43dd0..5d992eec52 100644 --- a/public/language/it/admin/manage/uploads.json +++ b/public/language/it/admin/manage/uploads.json @@ -6,6 +6,6 @@ "size/filecount": "Dimensione / Numero file", "confirm-delete": "Vuoi davvero cancellare questo file?", "filecount": "%1 file", - "new-folder": "New Folder", - "name-new-folder": "Enter a name for new the folder" + "new-folder": "Nuova cartella", + "name-new-folder": "Inserisci un nome per la nuova cartella" } \ No newline at end of file diff --git a/public/language/it/error.json b/public/language/it/error.json index 166ee800fa..c4a2350d94 100644 --- a/public/language/it/error.json +++ b/public/language/it/error.json @@ -25,14 +25,14 @@ "invalid-event": "Evento non valido: %1", "local-login-disabled": "Il sistema di accesso locale è stato disabilitato per gli account senza privilegi.", "csrf-invalid": "Non siamo riusciti a farti accedere, probabilmente perché la sessione è scaduta. Per favore riprova.", - "invalid-path": "Invalid path", - "folder-exists": "Folder exists", + "invalid-path": "Percorso non valido", + "folder-exists": "La cartella esiste", "invalid-pagination-value": "Valore di impaginazione non valido, deve essere almeno %1 ed al massimo %2", "username-taken": "Nome utente già esistente", "email-taken": "Email già esistente", "email-nochange": "L'email inserita è la stessa dell'email già presente in archivio.", "email-invited": "L'email è già stata invitata", - "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", + "email-not-confirmed": "Sarai abilitato a postare in alcune categorie o discussioni una volta che la tua email sarà confermata, per favore clicca qui per inviare una email di conferma.", "email-not-confirmed-chat": "Non puoi chattare finché non confermi la tua email, per favore clicca qui per confermare la tua email.", "email-not-confirmed-email-sent": "La tua email non è stata ancora confermata, controlla la tua casella di posta per l'email di conferma. Non potrai pubblicare post o chattare fino a quando la tua email non sarà confermata.", "no-email-to-confirm": "Il tuo account non ha un'email impostata. Un'email è necessaria per il recupero dell'account. Clicca qui per inserire un'email.", From 338f90fc5ef1aebee090a98e9ccc03ea27bf0996 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Mon, 6 Sep 2021 18:38:20 +0000 Subject: [PATCH 024/412] fix(deps): update dependency nodebb-plugin-dbsearch to v5.0.3 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 4cf3e48156..2dce79299b 100644 --- a/install/package.json +++ b/install/package.json @@ -85,7 +85,7 @@ "@nodebb/bootswatch": "3.4.2", "nconf": "^0.11.2", "nodebb-plugin-composer-default": "7.0.2", - "nodebb-plugin-dbsearch": "5.0.2", + "nodebb-plugin-dbsearch": "5.0.3", "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.3", From a17ffcd094114f525eae3729de8186c98e3fd5ff Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Tue, 7 Sep 2021 09:06:24 +0000 Subject: [PATCH 025/412] Latest translations and fallbacks --- public/language/sl/admin/admin.json | 6 +++--- public/language/sl/category.json | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/public/language/sl/admin/admin.json b/public/language/sl/admin/admin.json index 36f0fdde60..3afbbf5ab7 100644 --- a/public/language/sl/admin/admin.json +++ b/public/language/sl/admin/admin.json @@ -1,7 +1,7 @@ { - "alert.confirm-rebuild-and-restart": "Are you sure you wish to rebuild and restart NodeBB?", - "alert.confirm-restart": "Are you sure you wish to restart NodeBB?", + "alert.confirm-rebuild-and-restart": "Ste prepričani, da želite znova zagnati NodeBB?", + "alert.confirm-restart": "Ste prepričani, da želite znova zagnati NodeBB?", - "acp-title": "%1 | NodeBB Admin Control Panel", + "acp-title": "NodeBB administracijska nadzorna plošča", "settings-header-contents": "Contents" } \ No newline at end of file diff --git a/public/language/sl/category.json b/public/language/sl/category.json index 6a7fda2a16..e96e8805f9 100644 --- a/public/language/sl/category.json +++ b/public/language/sl/category.json @@ -10,9 +10,9 @@ "watch": "Spremljaj.", "ignore": "Prezri.", "watching": "Spremljano", - "not-watching": "Not Watching", + "not-watching": "Ni spremljano", "ignoring": "Prezrto", - "watching.description": "Show topics in unread and recent", + "watching.description": "Prikaži teme v nedavno in nazadnje", "not-watching.description": "Do not show topics in unread, show in recent", "ignoring.description": "Do not show topics in unread and recent", "watching.message": "You are now watching updates from this category and all subcategories", From ac6cd02fa2a582de4c0209a92cc1be556ff3cafe Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 7 Sep 2021 10:58:58 +0000 Subject: [PATCH 026/412] fix(deps): update dependency sharp to v0.29.1 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 2dce79299b..1cb2211274 100644 --- a/install/package.json +++ b/install/package.json @@ -116,7 +116,7 @@ "sanitize-html": "^2.3.2", "semver": "^7.3.4", "serve-favicon": "^2.5.0", - "sharp": "0.29.0", + "sharp": "0.29.1", "sitemap": "^7.0.0", "slideout": "1.0.1", "socket.io": "4.2.0", From 580a016b0ecc5e503f82dd9279066f16aeb1427c Mon Sep 17 00:00:00 2001 From: psychobunny Date: Tue, 7 Sep 2021 10:22:09 -0400 Subject: [PATCH 027/412] fix: #9767 ACP change group icon fix --- public/less/admin/manage/groups.less | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/public/less/admin/manage/groups.less b/public/less/admin/manage/groups.less index dda50c5c54..2183cc748c 100644 --- a/public/less/admin/manage/groups.less +++ b/public/less/admin/manage/groups.less @@ -35,4 +35,18 @@ [component="category/list"] li { cursor: pointer; } + + .fa-nbb-none { + border: 1px dotted black; + height: 35px; + width: 35px; + } + + .fa-icons .fa-nbb-none { + vertical-align: -6px; + } + + #group-icon-preview.fa-nbb-none { + display: none; + } } \ No newline at end of file From a7855c4cc4993b30ceaed6bc658bddfd70ba6b03 Mon Sep 17 00:00:00 2001 From: psychobunny Date: Tue, 7 Sep 2021 10:48:03 -0400 Subject: [PATCH 028/412] fix: dashboard graph controls --- src/views/admin/partials/dashboard/graph.tpl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/views/admin/partials/dashboard/graph.tpl b/src/views/admin/partials/dashboard/graph.tpl index d2604f2332..ee55cd7ce1 100644 --- a/src/views/admin/partials/dashboard/graph.tpl +++ b/src/views/admin/partials/dashboard/graph.tpl @@ -2,8 +2,10 @@
[[admin/dashboard:forum-traffic]]
- - + +
+
+
From bf0c02a71e744d349fe17bc7b89159c9d6cd3ce7 Mon Sep 17 00:00:00 2001 From: psychobunny Date: Tue, 7 Sep 2021 11:49:43 -0400 Subject: [PATCH 029/412] feat: a slightly less ugly rewards panel --- .../language/en-GB/admin/extend/rewards.json | 2 - public/less/admin/extend/rewards.less | 30 ++++ public/src/admin/extend/rewards.js | 4 +- src/views/admin/extend/rewards.tpl | 144 +++++++++--------- 4 files changed, 107 insertions(+), 73 deletions(-) diff --git a/public/language/en-GB/admin/extend/rewards.json b/public/language/en-GB/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/en-GB/admin/extend/rewards.json +++ b/public/language/en-GB/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/less/admin/extend/rewards.less b/public/less/admin/extend/rewards.less index 2dc84b5bc3..3972b16de3 100644 --- a/public/less/admin/extend/rewards.less +++ b/public/less/admin/extend/rewards.less @@ -16,6 +16,36 @@ > li { border-bottom: 1px solid #ddd; margin-bottom: 20px; + &:last-child { + border-bottom: 0; + } + } + } + + .rewards { width: 100%; } + + .well { + border-radius: 2px; + border-width: 2px; + color: #333; + + &.if-block { + border-color: @brand-primary; + } + &.this-block { + border-color: @brand-warning; + } + &.then-block { + border-color: @brand-success; + } + &.reward-block { + border-color: @brand-success; + background-color: lighten(@brand-success, 15%); + color: #fff; + a, select, input { color: #fff; } + select > option { color: #333; } + width: 100%; + min-height: 110px; } } } \ No newline at end of file diff --git a/public/src/admin/extend/rewards.js b/public/src/admin/extend/rewards.js index 3850b24017..7df62a7e15 100644 --- a/public/src/admin/extend/rewards.js +++ b/public/src/admin/extend/rewards.js @@ -95,13 +95,13 @@ define('admin/extend/rewards', [], function () { html += '
'; diff --git a/src/views/admin/extend/rewards.tpl b/src/views/admin/extend/rewards.tpl index bd226cc39d..456ab7d379 100644 --- a/src/views/admin/extend/rewards.tpl +++ b/src/views/admin/extend/rewards.tpl @@ -1,76 +1,82 @@ -
-
-
-
[[admin/extend/rewards:rewards]]
-
-
    - {{{ each active }}} -
  • -
    -
    -
    - -
    -
    -
    - - -
    -
    -
    - -
    -
    -
    -
    -
    -
    - -
    -
    -
    -
    - - [[admin/extend/rewards:zero-infinite]] -
    -
    -
    - - - - - - +
    +
      + {{{ each active }}} +
    • +
      +
      +
      +
      +
      + +
      +
      +
      +
      +
      + +
      +
      + +
      -
      -
    • - {{{ end }}} -
    +
    +
    + +
    + +
    +
    +
    +
    +
    +
    +
    + +
    +
    +
    +
    + +
    +
    -
    -
-
-
-
[[admin/extend/rewards:control-panel]]
-
- - +
+
+ + + + + + +
-
-
+
+ + {{{ end }}} + +
+ +
+ + +
\ No newline at end of file From 507517fce5248ad37f6a239fce16ae92d0e0f5b0 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 8 Sep 2021 09:06:50 +0000 Subject: [PATCH 030/412] Latest translations and fallbacks --- public/language/ar/admin/extend/rewards.json | 2 -- public/language/bg/admin/extend/rewards.json | 2 -- public/language/bn/admin/extend/rewards.json | 2 -- public/language/cs/admin/extend/rewards.json | 2 -- public/language/da/admin/extend/rewards.json | 2 -- public/language/de/admin/extend/rewards.json | 2 -- public/language/el/admin/extend/rewards.json | 2 -- public/language/en-US/admin/extend/rewards.json | 2 -- public/language/en-x-pirate/admin/extend/rewards.json | 2 -- public/language/es/admin/extend/rewards.json | 2 -- public/language/et/admin/extend/rewards.json | 2 -- public/language/fa-IR/admin/extend/rewards.json | 2 -- public/language/fi/admin/extend/rewards.json | 2 -- public/language/fr/admin/extend/rewards.json | 2 -- public/language/gl/admin/extend/rewards.json | 2 -- public/language/he/admin/extend/rewards.json | 2 -- public/language/hr/admin/extend/rewards.json | 2 -- public/language/hu/admin/extend/rewards.json | 2 -- public/language/id/admin/extend/rewards.json | 2 -- public/language/it/admin/extend/rewards.json | 2 -- public/language/ja/admin/extend/rewards.json | 2 -- public/language/ko/admin/extend/rewards.json | 2 -- public/language/lt/admin/extend/rewards.json | 2 -- public/language/lv/admin/extend/rewards.json | 2 -- public/language/ms/admin/extend/rewards.json | 2 -- public/language/nb/admin/extend/rewards.json | 2 -- public/language/nl/admin/extend/rewards.json | 2 -- public/language/pl/admin/extend/rewards.json | 2 -- public/language/pt-BR/admin/extend/rewards.json | 2 -- public/language/pt-PT/admin/extend/rewards.json | 2 -- public/language/ro/admin/extend/rewards.json | 2 -- public/language/ru/admin/extend/rewards.json | 2 -- public/language/rw/admin/extend/rewards.json | 2 -- public/language/sc/admin/extend/rewards.json | 2 -- public/language/sk/admin/extend/rewards.json | 2 -- public/language/sl/admin/extend/rewards.json | 2 -- public/language/sr/admin/extend/rewards.json | 2 -- public/language/sv/admin/extend/rewards.json | 2 -- public/language/th/admin/extend/rewards.json | 2 -- public/language/tr/admin/extend/rewards.json | 2 -- public/language/uk/admin/extend/rewards.json | 2 -- public/language/vi/admin/extend/rewards.json | 2 -- public/language/zh-CN/admin/extend/rewards.json | 2 -- public/language/zh-TW/admin/extend/rewards.json | 2 -- 44 files changed, 88 deletions(-) diff --git a/public/language/ar/admin/extend/rewards.json b/public/language/ar/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/ar/admin/extend/rewards.json +++ b/public/language/ar/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/bg/admin/extend/rewards.json b/public/language/bg/admin/extend/rewards.json index 890cc63d9e..d8860e3193 100644 --- a/public/language/bg/admin/extend/rewards.json +++ b/public/language/bg/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Изтриване", "enable": "Включване", "disable": "Изключване", - "control-panel": "Управление на наградите", - "new-reward": "Нова награда", "alert.delete-success": "Наградата е изтрита успешно", "alert.no-inputs-found": "Неправомерна награда — няма нищо въведено!", diff --git a/public/language/bn/admin/extend/rewards.json b/public/language/bn/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/bn/admin/extend/rewards.json +++ b/public/language/bn/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/cs/admin/extend/rewards.json b/public/language/cs/admin/extend/rewards.json index dd95f17371..9f0d26cfc3 100644 --- a/public/language/cs/admin/extend/rewards.json +++ b/public/language/cs/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Odstranit", "enable": "Povolit", "disable": "Zakázat", - "control-panel": "Ovládací panel odměn", - "new-reward": "Nová odměna", "alert.delete-success": "Odměna byla úspěšně smazána", "alert.no-inputs-found": "Nepovolená odměna – nebyl nalezen žádný záznam.", diff --git a/public/language/da/admin/extend/rewards.json b/public/language/da/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/da/admin/extend/rewards.json +++ b/public/language/da/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/de/admin/extend/rewards.json b/public/language/de/admin/extend/rewards.json index 38c39fcf44..7a6eef6513 100644 --- a/public/language/de/admin/extend/rewards.json +++ b/public/language/de/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Entfernen", "enable": "Aktivieren", "disable": "Deaktivieren", - "control-panel": "Belohnungseinstellungen", - "new-reward": "Neue Belohnung", "alert.delete-success": "Die Belohnung wurde erfolgreich gelöscht", "alert.no-inputs-found": "Ungültige Belohnung - keine Eingaben gefunden!", diff --git a/public/language/el/admin/extend/rewards.json b/public/language/el/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/el/admin/extend/rewards.json +++ b/public/language/el/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/en-US/admin/extend/rewards.json b/public/language/en-US/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/en-US/admin/extend/rewards.json +++ b/public/language/en-US/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/en-x-pirate/admin/extend/rewards.json b/public/language/en-x-pirate/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/en-x-pirate/admin/extend/rewards.json +++ b/public/language/en-x-pirate/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/es/admin/extend/rewards.json b/public/language/es/admin/extend/rewards.json index 44eb3f7108..98ded7cfa7 100644 --- a/public/language/es/admin/extend/rewards.json +++ b/public/language/es/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Eliminar", "enable": "Habilitar", "disable": "Deshabilitar", - "control-panel": "Control de recompensas", - "new-reward": "Nueva Recompensa", "alert.delete-success": "Recompensa eliminada con éxito", "alert.no-inputs-found": "¡Recompensa ilegal - no se encontraron inputs!", diff --git a/public/language/et/admin/extend/rewards.json b/public/language/et/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/et/admin/extend/rewards.json +++ b/public/language/et/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/fa-IR/admin/extend/rewards.json b/public/language/fa-IR/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/fa-IR/admin/extend/rewards.json +++ b/public/language/fa-IR/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/fi/admin/extend/rewards.json b/public/language/fi/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/fi/admin/extend/rewards.json +++ b/public/language/fi/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/fr/admin/extend/rewards.json b/public/language/fr/admin/extend/rewards.json index b1db437fc0..9fb342ce60 100644 --- a/public/language/fr/admin/extend/rewards.json +++ b/public/language/fr/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Supprimer", "enable": "Activer", "disable": "Désactiver", - "control-panel": "Contrôle des récompenses", - "new-reward": "Nouvelle récompense", "alert.delete-success": "Récompense supprimée", "alert.no-inputs-found": "Récompense invalide - aucune entrée trouvée !", diff --git a/public/language/gl/admin/extend/rewards.json b/public/language/gl/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/gl/admin/extend/rewards.json +++ b/public/language/gl/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/he/admin/extend/rewards.json b/public/language/he/admin/extend/rewards.json index 55adfcb6e2..12bc679568 100644 --- a/public/language/he/admin/extend/rewards.json +++ b/public/language/he/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "מחק", "enable": "הפעל", "disable": "השבת", - "control-panel": "בקרת תגמולים", - "new-reward": "תגמול חדש", "alert.delete-success": "תגמול נמחק בהצלחה", "alert.no-inputs-found": "תגמול לא חוקי - לא נמצא מידע!", diff --git a/public/language/hr/admin/extend/rewards.json b/public/language/hr/admin/extend/rewards.json index 5e20c3872f..d8198466a2 100644 --- a/public/language/hr/admin/extend/rewards.json +++ b/public/language/hr/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Obriši", "enable": "Omogući", "disable": "onemogući", - "control-panel": "Kontrola nagrada", - "new-reward": "Nova nagrada", "alert.delete-success": "Uspješno obrisana nagrada", "alert.no-inputs-found": "Ilegalna nagrada - nije pronađen unos!", diff --git a/public/language/hu/admin/extend/rewards.json b/public/language/hu/admin/extend/rewards.json index 1258e3a0c6..d5fe130fe8 100644 --- a/public/language/hu/admin/extend/rewards.json +++ b/public/language/hu/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Törlés", "enable": "Engedélyezés", "disable": "Tiltás", - "control-panel": "Jutalom vezérlés", - "new-reward": "Új jutalom", "alert.delete-success": "Jutalom sikeresen törölve", "alert.no-inputs-found": "Helytelen jutalom - nem található bevitel!", diff --git a/public/language/id/admin/extend/rewards.json b/public/language/id/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/id/admin/extend/rewards.json +++ b/public/language/id/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/it/admin/extend/rewards.json b/public/language/it/admin/extend/rewards.json index 1f1e6bc50f..7778999fbd 100644 --- a/public/language/it/admin/extend/rewards.json +++ b/public/language/it/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Elimina", "enable": "Abilita", "disable": "Disabilita", - "control-panel": "Controllo dei premi", - "new-reward": "Nuovo premio", "alert.delete-success": "Premi eliminati con successo", "alert.no-inputs-found": "Premio illegale - immissioni non trovate!", diff --git a/public/language/ja/admin/extend/rewards.json b/public/language/ja/admin/extend/rewards.json index 3023baeba3..72ef6500b8 100644 --- a/public/language/ja/admin/extend/rewards.json +++ b/public/language/ja/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "削除", "enable": "有効", "disable": "無効", - "control-panel": "報酬コントロール", - "new-reward": "新しい報酬", "alert.delete-success": "報酬を削除しました", "alert.no-inputs-found": "違法報酬 - 入力が見つかりません!", diff --git a/public/language/ko/admin/extend/rewards.json b/public/language/ko/admin/extend/rewards.json index ac23d6e380..be8bd8cf85 100644 --- a/public/language/ko/admin/extend/rewards.json +++ b/public/language/ko/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "삭제", "enable": "활성화", "disable": "비활성화", - "control-panel": "보상 제어판", - "new-reward": "새로운 보상", "alert.delete-success": "성공적으로 보상을 삭제했습니다.", "alert.no-inputs-found": "잘못된 보상 - 입력값이 없습니다!", diff --git a/public/language/lt/admin/extend/rewards.json b/public/language/lt/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/lt/admin/extend/rewards.json +++ b/public/language/lt/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/lv/admin/extend/rewards.json b/public/language/lv/admin/extend/rewards.json index ae99c8e088..97cf227477 100644 --- a/public/language/lv/admin/extend/rewards.json +++ b/public/language/lv/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Izdzēst", "enable": "Iespējot", "disable": "Atspējot", - "control-panel": "Balvu vadības panelis", - "new-reward": "Jauna balva", "alert.delete-success": "Veiksmīgi izdzēsta balva", "alert.no-inputs-found": "Nederīga balva - nav ievažu!", diff --git a/public/language/ms/admin/extend/rewards.json b/public/language/ms/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/ms/admin/extend/rewards.json +++ b/public/language/ms/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/nb/admin/extend/rewards.json b/public/language/nb/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/nb/admin/extend/rewards.json +++ b/public/language/nb/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/nl/admin/extend/rewards.json b/public/language/nl/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/nl/admin/extend/rewards.json +++ b/public/language/nl/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/pl/admin/extend/rewards.json b/public/language/pl/admin/extend/rewards.json index 41694a7ed8..afe04e15af 100644 --- a/public/language/pl/admin/extend/rewards.json +++ b/public/language/pl/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Usuń", "enable": "Włącz", "disable": "Wyłącz", - "control-panel": "Ustawienia nagród", - "new-reward": "Nowa nagroda", "alert.delete-success": "Pomyślnie usunięto nagrodę", "alert.no-inputs-found": "Niepoprawnie dodana nagroda ", diff --git a/public/language/pt-BR/admin/extend/rewards.json b/public/language/pt-BR/admin/extend/rewards.json index 4b9c21f169..08b1de8119 100644 --- a/public/language/pt-BR/admin/extend/rewards.json +++ b/public/language/pt-BR/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Deletar", "enable": "Ativar", "disable": "Desativar", - "control-panel": "Controle de Recompensas", - "new-reward": "Nova Recompensa", "alert.delete-success": "Recompensa excluída com sucesso", "alert.no-inputs-found": "Recompensa ilegal - nenhuma entrada encontrada!", diff --git a/public/language/pt-PT/admin/extend/rewards.json b/public/language/pt-PT/admin/extend/rewards.json index 7fab3c6679..346eb49e2a 100644 --- a/public/language/pt-PT/admin/extend/rewards.json +++ b/public/language/pt-PT/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Apagar", "enable": "Ativar", "disable": "Desativar", - "control-panel": "Controlo de Recompensas", - "new-reward": "Nova Recompensa", "alert.delete-success": "Recompensa apagada com sucesso", "alert.no-inputs-found": "Recompensa ilegal - não foram encontradas entradas!", diff --git a/public/language/ro/admin/extend/rewards.json b/public/language/ro/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/ro/admin/extend/rewards.json +++ b/public/language/ro/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/ru/admin/extend/rewards.json b/public/language/ru/admin/extend/rewards.json index 616afc7178..d6cc9c4623 100644 --- a/public/language/ru/admin/extend/rewards.json +++ b/public/language/ru/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Удалить", "enable": "Включить", "disable": "Выключить", - "control-panel": "Управление наградами", - "new-reward": "Новая награда", "alert.delete-success": "Награда успешно удалена", "alert.no-inputs-found": "Некорректная награда!", diff --git a/public/language/rw/admin/extend/rewards.json b/public/language/rw/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/rw/admin/extend/rewards.json +++ b/public/language/rw/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/sc/admin/extend/rewards.json b/public/language/sc/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/sc/admin/extend/rewards.json +++ b/public/language/sc/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/sk/admin/extend/rewards.json b/public/language/sk/admin/extend/rewards.json index e5a4a84acd..87a475ac61 100644 --- a/public/language/sk/admin/extend/rewards.json +++ b/public/language/sk/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Odstrániť", "enable": "Povoliť", "disable": "Zakázať", - "control-panel": "Kontrola odmien", - "new-reward": "Nová odmena", "alert.delete-success": "Odmena bola úspešne vymazaná", "alert.no-inputs-found": "Nepovolená odmena - nebol nájdený žiadny záznam.", diff --git a/public/language/sl/admin/extend/rewards.json b/public/language/sl/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/sl/admin/extend/rewards.json +++ b/public/language/sl/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/sr/admin/extend/rewards.json b/public/language/sr/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/sr/admin/extend/rewards.json +++ b/public/language/sr/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/sv/admin/extend/rewards.json b/public/language/sv/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/sv/admin/extend/rewards.json +++ b/public/language/sv/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/th/admin/extend/rewards.json b/public/language/th/admin/extend/rewards.json index 5383a90b33..df89d441a7 100644 --- a/public/language/th/admin/extend/rewards.json +++ b/public/language/th/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Delete", "enable": "Enable", "disable": "Disable", - "control-panel": "Rewards Control", - "new-reward": "New Reward", "alert.delete-success": "Successfully deleted reward", "alert.no-inputs-found": "Illegal reward - no inputs found!", diff --git a/public/language/tr/admin/extend/rewards.json b/public/language/tr/admin/extend/rewards.json index ff2dca964a..282c929757 100644 --- a/public/language/tr/admin/extend/rewards.json +++ b/public/language/tr/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Sil", "enable": "Etkinleştir", "disable": "Etkinsizleştir", - "control-panel": "Ödül Kontrol Paneli", - "new-reward": "Yeni Ödül Ekle", "alert.delete-success": "Ödül başarıyla silindi", "alert.no-inputs-found": "Usulsüz ödül - girdi bulunamadı!", diff --git a/public/language/uk/admin/extend/rewards.json b/public/language/uk/admin/extend/rewards.json index a3ba8e3b5c..47a0dd459d 100644 --- a/public/language/uk/admin/extend/rewards.json +++ b/public/language/uk/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Видалити", "enable": "Увімкнути", "disable": "Вимкнути", - "control-panel": "Керування нагородами", - "new-reward": "Нова нагорода", "alert.delete-success": "Нагороду успішно видалено", "alert.no-inputs-found": "Невірна нагорода — поля пусті!", diff --git a/public/language/vi/admin/extend/rewards.json b/public/language/vi/admin/extend/rewards.json index 89c006fe45..d7a803ae6a 100644 --- a/public/language/vi/admin/extend/rewards.json +++ b/public/language/vi/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "Xóa", "enable": "Bật", "disable": "Tắt", - "control-panel": "Kiểm Soát Phần Thưởng", - "new-reward": "Phần Thưởng Mới", "alert.delete-success": "Đã xóa thành công phần thưởng", "alert.no-inputs-found": "Phần thưởng không hợp lệ - không tìm thấy đầu vào!", diff --git a/public/language/zh-CN/admin/extend/rewards.json b/public/language/zh-CN/admin/extend/rewards.json index 12a4336ef0..7646b33976 100644 --- a/public/language/zh-CN/admin/extend/rewards.json +++ b/public/language/zh-CN/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "删除", "enable": "启用", "disable": "禁用", - "control-panel": "奖励控制", - "new-reward": "新奖励", "alert.delete-success": "已成功删除奖励", "alert.no-inputs-found": "非法奖励 - 输入为空!", diff --git a/public/language/zh-TW/admin/extend/rewards.json b/public/language/zh-TW/admin/extend/rewards.json index 19ef749362..924bc85f71 100644 --- a/public/language/zh-TW/admin/extend/rewards.json +++ b/public/language/zh-TW/admin/extend/rewards.json @@ -8,8 +8,6 @@ "delete": "刪除", "enable": "啟用", "disable": "禁用", - "control-panel": "獎勵控制", - "new-reward": "新獎勵", "alert.delete-success": "已成功刪除獎勵", "alert.no-inputs-found": "非法獎勵 - 輸入為空!", From 854c078b7385ce9f84850e09c8a6d8cd654aaca2 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 8 Sep 2021 16:27:00 +0000 Subject: [PATCH 031/412] chore: incrementing version number - v1.18.2 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 1cb2211274..3f2f772b16 100644 --- a/install/package.json +++ b/install/package.json @@ -2,7 +2,7 @@ "name": "nodebb", "license": "GPL-3.0", "description": "NodeBB Forum", - "version": "1.18.1", + "version": "1.18.2", "homepage": "http://www.nodebb.org", "repository": { "type": "git", From 27e9282aa47d8181a19f1d3df233bb7cf3c27147 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 8 Sep 2021 16:27:01 +0000 Subject: [PATCH 032/412] chore: update changelog for v1.18.2 --- CHANGELOG.md | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 466a49bd4a..2331add3ab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,46 @@ +#### v1.18.2 (2021-09-08) + +##### Chores + +* **deps:** update commitlint monorepo to v13 (87ba768f) +* incrementing version number - v1.18.1 (f8f80e4f) +* update changelog for v1.18.1 (0713475d) + +##### New Features + +* a slightly less ugly rewards panel (bf0c02a7) + +##### Bug Fixes + +* dashboard graph controls (a7855c4c) +* #9767 ACP change group icon fix (580a016b) +* #9781 (#9782) (0ce4b87d) +* replace logic in isPrivilegedOrSelfAndPasswordMatch to use privileges.users.canEdit (856ba78a) +* handle missing uid in deprecated socket call (cdaea611) +* use privileges.users.canEdit for image upload priv check (e33e046f) +* errors from registerComplete (a48bbdbf) +* simplify logic for fullname and email blanking in user retrieval (getUserDataByUserSlug) (60de0844) +* lint (1e2bda13) +* manifest error (488f0978) +* #9772, regression from https://github.com/NodeBB/NodeBB/commit/70a04bc10577e90e28d66a647d38cafc3307a285 (72710b80) +* push back some deprecations, remove deprecated stuff scheduled for v1.18.0 (dd4e66e2) +* deprecate userData.showHidden as it is functionally equivalent to userData.canEdit (4ac701d7) +* focus on save button on plugin activation (46e5e17d) +* #9773, fire hooks properly for priv changes (#9774) (6869920e) +* **deps:** + * update dependency sharp to v0.29.1 (ac6cd02f) + * update dependency nodebb-plugin-dbsearch to v5.0.3 (338f90fc) + * update dependency nodebb-theme-vanilla to v12.1.3 (0b3ea5ad) + * update dependency nodebb-theme-persona to v11.2.5 (57e54d55) + +##### Refactors + +* deprecate picture update socket call, new API routes for picture update (0a41741b) + +##### Tests + +* added test for external image via new change picture API (8cbad61e) + #### v1.18.1 (2021-09-03) ##### Chores From 0a56158bb42659b069aa7323f4944f7950f7915e Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 8 Sep 2021 16:27:00 +0000 Subject: [PATCH 033/412] chore: incrementing version number - v1.18.2 (cherry picked from commit 854c078b7385ce9f84850e09c8a6d8cd654aaca2) Signed-off-by: Misty (Bot) --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 1cb2211274..3f2f772b16 100644 --- a/install/package.json +++ b/install/package.json @@ -2,7 +2,7 @@ "name": "nodebb", "license": "GPL-3.0", "description": "NodeBB Forum", - "version": "1.18.1", + "version": "1.18.2", "homepage": "http://www.nodebb.org", "repository": { "type": "git", From 34afb7476254eee2d94e55e04f5a5f74c2db2f67 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Wed, 8 Sep 2021 14:05:51 -0400 Subject: [PATCH 034/412] fix: browsers autocompleting smtp fields when they should not --- src/views/admin/settings/email.tpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/views/admin/settings/email.tpl b/src/views/admin/settings/email.tpl index 1a8e98177e..76286d117e 100644 --- a/src/views/admin/settings/email.tpl +++ b/src/views/admin/settings/email.tpl @@ -122,14 +122,14 @@
- +

[[admin/settings/email:smtp-transport.username-help]]

- +
From 006fc700ddc6b9a17e87e9210c8a5eadf127e233 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Wed, 8 Sep 2021 14:18:20 -0400 Subject: [PATCH 035/412] feat: add ACP option to require email address on new registration --- public/language/en-GB/admin/settings/email.json | 2 ++ src/user/interstitials.js | 12 +++++++++--- src/views/admin/settings/email.tpl | 8 ++++++++ 3 files changed, 19 insertions(+), 3 deletions(-) diff --git a/public/language/en-GB/admin/settings/email.json b/public/language/en-GB/admin/settings/email.json index 9bdbde26a6..af4e100eb6 100644 --- a/public/language/en-GB/admin/settings/email.json +++ b/public/language/en-GB/admin/settings/email.json @@ -37,6 +37,8 @@ "subscriptions.hour": "Digest Hour", "subscriptions.hour-help": "Please enter a number representing the hour to send scheduled email digests (e.g. 0 for midnight, 17 for 5:00pm). Keep in mind that this is the hour according to the server itself, and may not exactly match your system clock.
The approximate server time is:
The next daily digest is scheduled to be sent ", "notifications.remove-images": "Remove images from email notifications", + "require-email-address": "Require new users to specify an email address", + "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." } \ No newline at end of file diff --git a/src/user/interstitials.js b/src/user/interstitials.js index 5467711503..3a98b12373 100644 --- a/src/user/interstitials.js +++ b/src/user/interstitials.js @@ -57,9 +57,15 @@ Interstitials.email = async (data) => { // User attempting to edit another user's email -- not allowed throw new Error('[[error:no-privileges]]'); } - } else if (current) { - // User explicitly clearing their email - await user.email.remove(userData.uid, data.req.session.id); + } else { + if (meta.config.requireEmailAddress) { + throw new Error('[[error:invalid-email]]'); + } + + if (current) { + // User explicitly clearing their email + await user.email.remove(userData.uid, data.req.session.id); + } } } else { // New registrants have the confirm email sent from user.create() diff --git a/src/views/admin/settings/email.tpl b/src/views/admin/settings/email.tpl index 76286d117e..9d33950d7a 100644 --- a/src/views/admin/settings/email.tpl +++ b/src/views/admin/settings/email.tpl @@ -27,6 +27,14 @@
+
+ +
+

[[admin/settings/email:require-email-address-warning]]

+
+
\ No newline at end of file diff --git a/src/views/admin/partials/menu.tpl b/src/views/admin/partials/menu.tpl index f519ecd475..343ba8445c 100644 --- a/src/views/admin/partials/menu.tpl +++ b/src/views/admin/partials/menu.tpl @@ -184,6 +184,7 @@
  • [[admin/menu:dashboard/logins]]
  • [[admin/menu:dashboard/users]]
  • [[admin/menu:dashboard/topics]]
  • +
  • [[admin/menu:dashboard/searches]]
  • {{{ end }}} From abe59131dd8c7bd443d7d74089d13b63dcab501a Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Mon, 25 Oct 2021 20:28:14 +0000 Subject: [PATCH 274/412] chore(i18n): fallback strings for new resources: nodebb.admin-dashboard, nodebb.admin-menu --- public/language/ar/admin/dashboard.json | 7 ++++--- public/language/ar/admin/menu.json | 1 + public/language/bg/admin/dashboard.json | 7 ++++--- public/language/bg/admin/menu.json | 1 + public/language/bn/admin/dashboard.json | 7 ++++--- public/language/bn/admin/menu.json | 1 + public/language/cs/admin/dashboard.json | 7 ++++--- public/language/cs/admin/menu.json | 1 + public/language/da/admin/dashboard.json | 7 ++++--- public/language/da/admin/menu.json | 1 + public/language/de/admin/dashboard.json | 7 ++++--- public/language/de/admin/menu.json | 1 + public/language/el/admin/dashboard.json | 7 ++++--- public/language/el/admin/menu.json | 1 + public/language/en-US/admin/dashboard.json | 7 ++++--- public/language/en-US/admin/menu.json | 1 + public/language/en-x-pirate/admin/dashboard.json | 7 ++++--- public/language/en-x-pirate/admin/menu.json | 1 + public/language/es/admin/dashboard.json | 7 ++++--- public/language/es/admin/menu.json | 1 + public/language/et/admin/dashboard.json | 7 ++++--- public/language/et/admin/menu.json | 1 + public/language/fa-IR/admin/dashboard.json | 7 ++++--- public/language/fa-IR/admin/menu.json | 1 + public/language/fi/admin/dashboard.json | 7 ++++--- public/language/fi/admin/menu.json | 1 + public/language/fr/admin/dashboard.json | 7 ++++--- public/language/fr/admin/menu.json | 1 + public/language/gl/admin/dashboard.json | 7 ++++--- public/language/gl/admin/menu.json | 1 + public/language/he/admin/dashboard.json | 7 ++++--- public/language/he/admin/menu.json | 1 + public/language/hr/admin/dashboard.json | 7 ++++--- public/language/hr/admin/menu.json | 1 + public/language/hu/admin/dashboard.json | 7 ++++--- public/language/hu/admin/menu.json | 1 + public/language/id/admin/dashboard.json | 7 ++++--- public/language/id/admin/menu.json | 1 + public/language/it/admin/dashboard.json | 7 ++++--- public/language/it/admin/menu.json | 1 + public/language/ja/admin/dashboard.json | 7 ++++--- public/language/ja/admin/menu.json | 1 + public/language/ko/admin/dashboard.json | 7 ++++--- public/language/ko/admin/menu.json | 1 + public/language/lt/admin/dashboard.json | 7 ++++--- public/language/lt/admin/menu.json | 1 + public/language/lv/admin/dashboard.json | 7 ++++--- public/language/lv/admin/menu.json | 1 + public/language/ms/admin/dashboard.json | 7 ++++--- public/language/ms/admin/menu.json | 1 + public/language/nb/admin/dashboard.json | 7 ++++--- public/language/nb/admin/menu.json | 1 + public/language/nl/admin/dashboard.json | 7 ++++--- public/language/nl/admin/menu.json | 1 + public/language/pl/admin/dashboard.json | 7 ++++--- public/language/pl/admin/menu.json | 1 + public/language/pt-BR/admin/dashboard.json | 7 ++++--- public/language/pt-BR/admin/menu.json | 1 + public/language/pt-PT/admin/dashboard.json | 7 ++++--- public/language/pt-PT/admin/menu.json | 1 + public/language/ro/admin/dashboard.json | 7 ++++--- public/language/ro/admin/menu.json | 1 + public/language/ru/admin/dashboard.json | 7 ++++--- public/language/ru/admin/menu.json | 1 + public/language/rw/admin/dashboard.json | 7 ++++--- public/language/rw/admin/menu.json | 1 + public/language/sc/admin/dashboard.json | 7 ++++--- public/language/sc/admin/menu.json | 1 + public/language/sk/admin/dashboard.json | 7 ++++--- public/language/sk/admin/menu.json | 1 + public/language/sl/admin/dashboard.json | 7 ++++--- public/language/sl/admin/menu.json | 1 + public/language/sr/admin/dashboard.json | 7 ++++--- public/language/sr/admin/menu.json | 1 + public/language/sv/admin/dashboard.json | 7 ++++--- public/language/sv/admin/menu.json | 1 + public/language/th/admin/dashboard.json | 7 ++++--- public/language/th/admin/menu.json | 1 + public/language/tr/admin/dashboard.json | 7 ++++--- public/language/tr/admin/menu.json | 1 + public/language/uk/admin/dashboard.json | 7 ++++--- public/language/uk/admin/menu.json | 1 + public/language/vi/admin/dashboard.json | 7 ++++--- public/language/vi/admin/menu.json | 1 + public/language/zh-CN/admin/dashboard.json | 7 ++++--- public/language/zh-CN/admin/menu.json | 1 + public/language/zh-TW/admin/dashboard.json | 7 ++++--- public/language/zh-TW/admin/menu.json | 1 + 88 files changed, 220 insertions(+), 132 deletions(-) diff --git a/public/language/ar/admin/dashboard.json b/public/language/ar/admin/dashboard.json index baef0d2f11..b2a50f73de 100644 --- a/public/language/ar/admin/dashboard.json +++ b/public/language/ar/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "المجموع", "active-users.connections": "Connections", - "anonymous-registered-users": "المجهولين مقابل المستخدمين المسجلين", - "anonymous": "مجهول", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "مسجل", "user-presence": "تواجد المستخدمين", @@ -68,6 +68,7 @@ "unread": "غير مقروء", "high-presence-topics": "مواضيع ذات حضور قوي", + "popular-searches": "Popular Searches", "graphs.page-views": "مشاهدات الصفحة", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "زوار فريدين", "graphs.registered-users": "مستخدمين مسجلين", - "graphs.anonymous-users": "مستخدمين مجهولين", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/ar/admin/menu.json b/public/language/ar/admin/menu.json index e60767eab3..97d0fa4dfc 100644 --- a/public/language/ar/admin/menu.json +++ b/public/language/ar/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "عام", "section-manage": "إدارة", diff --git a/public/language/bg/admin/dashboard.json b/public/language/bg/admin/dashboard.json index 860d6c5ff7..1a7eb1ff43 100644 --- a/public/language/bg/admin/dashboard.json +++ b/public/language/bg/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Общо", "active-users.connections": "Връзки", - "anonymous-registered-users": "Анонимни към регистрирани потребители", - "anonymous": "Анонимни", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Регистрирани", "user-presence": "Присъствие на потребителите ", @@ -68,6 +68,7 @@ "unread": "Непрочетени", "high-presence-topics": "Теми с най-голяма присъственост", + "popular-searches": "Popular Searches", "graphs.page-views": "Преглеждания на страниците", "graphs.page-views-registered": "Преглеждания на страниците от регистрирани потребители", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Преглеждания на страниците от ботове", "graphs.unique-visitors": "Уникални посетители", "graphs.registered-users": "Регистрирани потребители", - "graphs.anonymous-users": "Анонимни потребители", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Последно рестартиране от", "no-users-browsing": "Няма разглеждащи потребители", diff --git a/public/language/bg/admin/menu.json b/public/language/bg/admin/menu.json index 4127603e4b..52ac9da1ba 100644 --- a/public/language/bg/admin/menu.json +++ b/public/language/bg/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Вписвания", "dashboard/users": "Потребители", "dashboard/topics": "Теми", + "dashboard/searches": "Searches", "section-general": "Общи", "section-manage": "Управление", diff --git a/public/language/bn/admin/dashboard.json b/public/language/bn/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/bn/admin/dashboard.json +++ b/public/language/bn/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/bn/admin/menu.json b/public/language/bn/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/bn/admin/menu.json +++ b/public/language/bn/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/cs/admin/dashboard.json b/public/language/cs/admin/dashboard.json index d0197077c9..637e35752e 100644 --- a/public/language/cs/admin/dashboard.json +++ b/public/language/cs/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Celkově", "active-users.connections": "Připojení", - "anonymous-registered-users": "Anonymní × registrovaní uživatelé", - "anonymous": "Anonymní", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registrovaní", "user-presence": "Výskyt uživatele", @@ -68,6 +68,7 @@ "unread": "Nepřečtené", "high-presence-topics": "Témata s vysokou účastí", + "popular-searches": "Popular Searches", "graphs.page-views": "Zobrazení stránky", "graphs.page-views-registered": "Zobrazených stránek/registrovaní", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Zobrazených stránek/bot", "graphs.unique-visitors": "Jedineční návštěvníci", "graphs.registered-users": "Registrovaní uživatelé", - "graphs.anonymous-users": "Anonymní uživatelé", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Poslední restart od", "no-users-browsing": "Nikdo si nic neprohlíží", diff --git a/public/language/cs/admin/menu.json b/public/language/cs/admin/menu.json index 9eee43ba3d..603d9616fe 100644 --- a/public/language/cs/admin/menu.json +++ b/public/language/cs/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Všeobecné", "section-manage": "Spravovat", diff --git a/public/language/da/admin/dashboard.json b/public/language/da/admin/dashboard.json index dbe77149a1..32a61894e5 100644 --- a/public/language/da/admin/dashboard.json +++ b/public/language/da/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/da/admin/menu.json b/public/language/da/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/da/admin/menu.json +++ b/public/language/da/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/de/admin/dashboard.json b/public/language/de/admin/dashboard.json index 943b0fcfa5..f3c744c715 100644 --- a/public/language/de/admin/dashboard.json +++ b/public/language/de/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Gesamt", "active-users.connections": "Verbindungen", - "anonymous-registered-users": "Anonyme vs Registrierte Benutzer", - "anonymous": "Anonym", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registriert", "user-presence": "Benutzerpräsenz", @@ -68,6 +68,7 @@ "unread": "Ungelesen", "high-presence-topics": "Meist besuchte Themen", + "popular-searches": "Popular Searches", "graphs.page-views": "Seitenaufrufe", "graphs.page-views-registered": "Registrierte Seitenaufrufe", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Seitenaufrufe von Bots", "graphs.unique-visitors": "Verschiedene Besucher", "graphs.registered-users": "Registrierte Benutzer", - "graphs.anonymous-users": "Anonyme Benutzer", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Zuletzt Neugestartet von: ", "no-users-browsing": "Keine aktiven Benutzer", diff --git a/public/language/de/admin/menu.json b/public/language/de/admin/menu.json index 13448137e8..ec21748e22 100644 --- a/public/language/de/admin/menu.json +++ b/public/language/de/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Allgemein", "section-manage": "Verwalten", diff --git a/public/language/el/admin/dashboard.json b/public/language/el/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/el/admin/dashboard.json +++ b/public/language/el/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/el/admin/menu.json b/public/language/el/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/el/admin/menu.json +++ b/public/language/el/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/en-US/admin/dashboard.json b/public/language/en-US/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/en-US/admin/dashboard.json +++ b/public/language/en-US/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/en-US/admin/menu.json b/public/language/en-US/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/en-US/admin/menu.json +++ b/public/language/en-US/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/en-x-pirate/admin/dashboard.json b/public/language/en-x-pirate/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/en-x-pirate/admin/dashboard.json +++ b/public/language/en-x-pirate/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/en-x-pirate/admin/menu.json b/public/language/en-x-pirate/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/en-x-pirate/admin/menu.json +++ b/public/language/en-x-pirate/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/es/admin/dashboard.json b/public/language/es/admin/dashboard.json index 7595d4a563..d8b98fbb7e 100644 --- a/public/language/es/admin/dashboard.json +++ b/public/language/es/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Conexiones", - "anonymous-registered-users": "Usuarios Anónimos vs Registrados", - "anonymous": "Anónimos", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registrados", "user-presence": "Presencia del Usuario", @@ -68,6 +68,7 @@ "unread": "Sin Leer", "high-presence-topics": "Temas con Alta Presencia", + "popular-searches": "Popular Searches", "graphs.page-views": "Vista de la Pagina", "graphs.page-views-registered": "Vistas de la página registradas", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Vistas de la página Bot", "graphs.unique-visitors": "Visitantes Unicos", "graphs.registered-users": "Usuarios Registrados", - "graphs.anonymous-users": "Usuarios Anónimos", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Reiniciado por última vez por", "no-users-browsing": "No hay usuarios explorando", diff --git a/public/language/es/admin/menu.json b/public/language/es/admin/menu.json index 6fa9453a06..d9e2ce06b3 100644 --- a/public/language/es/admin/menu.json +++ b/public/language/es/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Administrar", diff --git a/public/language/et/admin/dashboard.json b/public/language/et/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/et/admin/dashboard.json +++ b/public/language/et/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/et/admin/menu.json b/public/language/et/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/et/admin/menu.json +++ b/public/language/et/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/fa-IR/admin/dashboard.json b/public/language/fa-IR/admin/dashboard.json index bf2ce96962..e82461d99b 100644 --- a/public/language/fa-IR/admin/dashboard.json +++ b/public/language/fa-IR/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "نخوانده‌ها", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/fa-IR/admin/menu.json b/public/language/fa-IR/admin/menu.json index 9f65d917da..7fa68c6830 100644 --- a/public/language/fa-IR/admin/menu.json +++ b/public/language/fa-IR/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "عمومی", "section-manage": "Manage", diff --git a/public/language/fi/admin/dashboard.json b/public/language/fi/admin/dashboard.json index 8ce9c29ded..856db27e90 100644 --- a/public/language/fi/admin/dashboard.json +++ b/public/language/fi/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Kokonaisuudessaan", "active-users.connections": "Yhteyttä", - "anonymous-registered-users": "Anonyymit vs. Rekisteröityneet käyttäjät", - "anonymous": "Anonyymiä", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Rekisteröitynyttä", "user-presence": "Käyttäjien sijainti", @@ -68,6 +68,7 @@ "unread": "Lukemattomat", "high-presence-topics": "Aiheet, joissa on eniten käyttäjiä paikalla", + "popular-searches": "Popular Searches", "graphs.page-views": "Sivulataukset", "graphs.page-views-registered": "Rekisteröityneiden käyttäjien sivulatausta", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Bottien sivulatausta", "graphs.unique-visitors": "Uniikkia vierailijaa", "graphs.registered-users": "Rekisteröitynyttä käyttäjää", - "graphs.anonymous-users": "Anonyymiä käyttäjää", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Viimeksi uudelleenkäynnistetty", "no-users-browsing": "Ei käyttäjiä selaamassa", diff --git a/public/language/fi/admin/menu.json b/public/language/fi/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/fi/admin/menu.json +++ b/public/language/fi/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/fr/admin/dashboard.json b/public/language/fr/admin/dashboard.json index 6670e9d2db..411890f7de 100644 --- a/public/language/fr/admin/dashboard.json +++ b/public/language/fr/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connexions", - "anonymous-registered-users": "Utilisateurs anonymes vs enregistrés", - "anonymous": "Anonymes", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Enregistrés", "user-presence": "Présence des utilisateurs", @@ -68,6 +68,7 @@ "unread": "Non lus", "high-presence-topics": "Sujets populaires", + "popular-searches": "Popular Searches", "graphs.page-views": "Pages vues", "graphs.page-views-registered": "Membres", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Robots", "graphs.unique-visitors": "Visiteurs uniques", "graphs.registered-users": "Utilisateurs enregistrés", - "graphs.anonymous-users": "Utilisateurs anonymes", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Redémarré par", "no-users-browsing": "Aucun utilisateur connecté", diff --git a/public/language/fr/admin/menu.json b/public/language/fr/admin/menu.json index 3cb96440ec..dc12d9e9e1 100644 --- a/public/language/fr/admin/menu.json +++ b/public/language/fr/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Connexions", "dashboard/users": "Utilisateurs", "dashboard/topics": "Sujets", + "dashboard/searches": "Searches", "section-general": "Général", "section-manage": "Gestion", diff --git a/public/language/gl/admin/dashboard.json b/public/language/gl/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/gl/admin/dashboard.json +++ b/public/language/gl/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/gl/admin/menu.json b/public/language/gl/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/gl/admin/menu.json +++ b/public/language/gl/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/he/admin/dashboard.json b/public/language/he/admin/dashboard.json index 027b3f97a2..887fd70646 100644 --- a/public/language/he/admin/dashboard.json +++ b/public/language/he/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "סך הכל", "active-users.connections": "חיבורים", - "anonymous-registered-users": "משתמשים רשומים ואורחים", - "anonymous": "אורחים", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "רשומים", "user-presence": "נוכחות משתמשים", @@ -68,6 +68,7 @@ "unread": "לא נקראו", "high-presence-topics": "פוסטים עם הכי הרבה נוכחות", + "popular-searches": "Popular Searches", "graphs.page-views": "צפיות בדפים", "graphs.page-views-registered": "צפיות בדפים-רשומים", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "צפיות בדפים-בוטים", "graphs.unique-visitors": "מבקרים ייחודיים", "graphs.registered-users": "משתמשים רשומים", - "graphs.anonymous-users": "אורחים", + "graphs.guest-users": "Guest Users", "last-restarted-by": "אותחל לארונה על ידי", "no-users-browsing": "אין גולשים", diff --git a/public/language/he/admin/menu.json b/public/language/he/admin/menu.json index c4d31c775d..e18bb3012c 100644 --- a/public/language/he/admin/menu.json +++ b/public/language/he/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "כניסות", "dashboard/users": "משתמשים", "dashboard/topics": "נושאים", + "dashboard/searches": "Searches", "section-general": "כללי", "section-manage": "ניהול", diff --git a/public/language/hr/admin/dashboard.json b/public/language/hr/admin/dashboard.json index 7ce75d8880..a44e4d70be 100644 --- a/public/language/hr/admin/dashboard.json +++ b/public/language/hr/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Ukupno", "active-users.connections": "Veze", - "anonymous-registered-users": "Anonimni vs Registrirani korisnici", - "anonymous": "Anomiman", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registriran", "user-presence": "Korisnik prisutan", @@ -68,6 +68,7 @@ "unread": "Nepročitano", "high-presence-topics": "Teme visoke prisutnosti", + "popular-searches": "Popular Searches", "graphs.page-views": "Pregled stranica", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Jedninstveni posjetitelji", "graphs.registered-users": "Registrirani korisnici", - "graphs.anonymous-users": "Anonimni korisnici", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/hr/admin/menu.json b/public/language/hr/admin/menu.json index dcb1868922..4dd18a9204 100644 --- a/public/language/hr/admin/menu.json +++ b/public/language/hr/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Glavno", "section-manage": "Upravljanje", diff --git a/public/language/hu/admin/dashboard.json b/public/language/hu/admin/dashboard.json index 5d5c00b20f..6d446490ee 100644 --- a/public/language/hu/admin/dashboard.json +++ b/public/language/hu/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Összesen", "active-users.connections": "Kapcsolatok", - "anonymous-registered-users": "Névtelen vs regisztrált felhasználók", - "anonymous": "Névtelen", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Regisztrált", "user-presence": "Felhasználói jelenlét", @@ -68,6 +68,7 @@ "unread": "Olvasatlan", "high-presence-topics": "Témakörök nagy jelenléttel", + "popular-searches": "Popular Searches", "graphs.page-views": "Oldal megtekintések", "graphs.page-views-registered": "Regisztrált látogatások", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Bot látogatások", "graphs.unique-visitors": "Egyedi látogatók", "graphs.registered-users": "Regisztrált felhasználók", - "graphs.anonymous-users": "Névtelen felhasználók", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Utoljára újraindította:", "no-users-browsing": "Jelenleg nem böngész senki", diff --git a/public/language/hu/admin/menu.json b/public/language/hu/admin/menu.json index e28e561edc..e2329570bb 100644 --- a/public/language/hu/admin/menu.json +++ b/public/language/hu/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Bejelentkezések", "dashboard/users": "Felhasználók", "dashboard/topics": "Témakörök", + "dashboard/searches": "Searches", "section-general": "Általános", "section-manage": "Kezelés", diff --git a/public/language/id/admin/dashboard.json b/public/language/id/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/id/admin/dashboard.json +++ b/public/language/id/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/id/admin/menu.json b/public/language/id/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/id/admin/menu.json +++ b/public/language/id/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/it/admin/dashboard.json b/public/language/it/admin/dashboard.json index 121ab8e291..9947c2b5fd 100644 --- a/public/language/it/admin/dashboard.json +++ b/public/language/it/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Totale", "active-users.connections": "Connessioni", - "anonymous-registered-users": "Anonimi vs Utenti Registrati", - "anonymous": "Anonimi", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registrati", "user-presence": "Presenza utente", @@ -68,6 +68,7 @@ "unread": "Non letto", "high-presence-topics": "Alta presenza discussioni", + "popular-searches": "Popular Searches", "graphs.page-views": "Pagine viste", "graphs.page-views-registered": "Pagine viste Registrati", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Pagine viste Bot", "graphs.unique-visitors": "Visitatori Unici", "graphs.registered-users": "Utenti Registrati", - "graphs.anonymous-users": "Utenti Anonimi", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Ultimo riavvio di", "no-users-browsing": "Nessun utente sta navigando", diff --git a/public/language/it/admin/menu.json b/public/language/it/admin/menu.json index 1148c9b67d..9506af8a68 100644 --- a/public/language/it/admin/menu.json +++ b/public/language/it/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Accessi", "dashboard/users": "Utenti", "dashboard/topics": "Discussioni", + "dashboard/searches": "Searches", "section-general": "Generale", "section-manage": "Gestisci", diff --git a/public/language/ja/admin/dashboard.json b/public/language/ja/admin/dashboard.json index 4e719a00cd..f6cbb54b4a 100644 --- a/public/language/ja/admin/dashboard.json +++ b/public/language/ja/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "総合", "active-users.connections": "接続", - "anonymous-registered-users": "匿名 vs 登録ユーザー", - "anonymous": "匿名", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "登録数", "user-presence": "ユーザープレゼンス", @@ -68,6 +68,7 @@ "unread": "未読", "high-presence-topics": "ハイプレゼンススレッド", + "popular-searches": "Popular Searches", "graphs.page-views": "ページビュー", "graphs.page-views-registered": "ページビュー登録済み", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "ページビューBot", "graphs.unique-visitors": "ユニークな訪問者", "graphs.registered-users": "登録したユーザー", - "graphs.anonymous-users": "匿名ユーザー", + "graphs.guest-users": "Guest Users", "last-restarted-by": "最後に再起動された順", "no-users-browsing": "閲覧中のユーザーなし", diff --git a/public/language/ja/admin/menu.json b/public/language/ja/admin/menu.json index e7228820fb..35eec8d76c 100644 --- a/public/language/ja/admin/menu.json +++ b/public/language/ja/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "一般", "section-manage": "管理", diff --git a/public/language/ko/admin/dashboard.json b/public/language/ko/admin/dashboard.json index 64f29de725..dcc6afa567 100644 --- a/public/language/ko/admin/dashboard.json +++ b/public/language/ko/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "총", "active-users.connections": "연결", - "anonymous-registered-users": "익명 vs 가입한 사용자", - "anonymous": "익명", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "가입한 사용자", "user-presence": "사용자 활동", @@ -68,6 +68,7 @@ "unread": "읽지 않음", "high-presence-topics": "활동량이 많은 화제", + "popular-searches": "Popular Searches", "graphs.page-views": "페이지 뷰", "graphs.page-views-registered": "가입한 사용자의 페이지 뷰", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "봇의 페이지 뷰", "graphs.unique-visitors": "고유 방문자", "graphs.registered-users": "등록된 사용자", - "graphs.anonymous-users": "익명 사용자", + "graphs.guest-users": "Guest Users", "last-restarted-by": "최근 재시작 시점", "no-users-browsing": "보고있는 사용자 없음", diff --git a/public/language/ko/admin/menu.json b/public/language/ko/admin/menu.json index 3999230bcc..b28b897736 100644 --- a/public/language/ko/admin/menu.json +++ b/public/language/ko/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "로그인 기록", "dashboard/users": "사용자", "dashboard/topics": "화제", + "dashboard/searches": "Searches", "section-general": "일반", "section-manage": "관리", diff --git a/public/language/lt/admin/dashboard.json b/public/language/lt/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/lt/admin/dashboard.json +++ b/public/language/lt/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/lt/admin/menu.json b/public/language/lt/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/lt/admin/menu.json +++ b/public/language/lt/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/lv/admin/dashboard.json b/public/language/lv/admin/dashboard.json index 234cf4baee..698fe8392c 100644 --- a/public/language/lv/admin/dashboard.json +++ b/public/language/lv/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Kopēji", "active-users.connections": "Savienojumi", - "anonymous-registered-users": "Anonīmie lietotāji pret reģistrētiem lietotājiem", - "anonymous": "Anonīmie", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Reģistrētie", "user-presence": "Lietotāju novietojums", @@ -68,6 +68,7 @@ "unread": "Skatās nelasītos rakstus", "high-presence-topics": "Augstās klātesamības temati", + "popular-searches": "Popular Searches", "graphs.page-views": "Lapu skatījumi", "graphs.page-views-registered": "Lapu skatījumi no lietotājiem", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Lapu skatījumi no botiem", "graphs.unique-visitors": "Unikālie apmeklētāji", "graphs.registered-users": "Reģistrētie lietotāji", - "graphs.anonymous-users": "Anonīmie lietotāji", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Pēdējoreiz restartējis", "no-users-browsing": "Nav pārlūkojošo lietotāju", diff --git a/public/language/lv/admin/menu.json b/public/language/lv/admin/menu.json index bbf5d97854..c97b9b0cb3 100644 --- a/public/language/lv/admin/menu.json +++ b/public/language/lv/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Vispārējie", "section-manage": "Pārvaldīt", diff --git a/public/language/ms/admin/dashboard.json b/public/language/ms/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/ms/admin/dashboard.json +++ b/public/language/ms/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/ms/admin/menu.json b/public/language/ms/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/ms/admin/menu.json +++ b/public/language/ms/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/nb/admin/dashboard.json b/public/language/nb/admin/dashboard.json index 2f744a1182..73f19422c9 100644 --- a/public/language/nb/admin/dashboard.json +++ b/public/language/nb/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "Høyt synlige tråder", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/nb/admin/menu.json b/public/language/nb/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/nb/admin/menu.json +++ b/public/language/nb/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/nl/admin/dashboard.json b/public/language/nl/admin/dashboard.json index bb81461688..d18af4cb65 100644 --- a/public/language/nl/admin/dashboard.json +++ b/public/language/nl/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connecties", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Laatst herstart door", "no-users-browsing": "No users browsing", diff --git a/public/language/nl/admin/menu.json b/public/language/nl/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/nl/admin/menu.json +++ b/public/language/nl/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/pl/admin/dashboard.json b/public/language/pl/admin/dashboard.json index 1ca20bba1b..8b7d92b6e3 100644 --- a/public/language/pl/admin/dashboard.json +++ b/public/language/pl/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Łącznie", "active-users.connections": "Połączenia", - "anonymous-registered-users": "Użytkownicy anonimowi vs zarejestrowani", - "anonymous": "Anonimowi", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Zarejestrowani", "user-presence": "Obecność użytkownika", @@ -68,6 +68,7 @@ "unread": "Nieprzeczytane", "high-presence-topics": "Popularne tematy", + "popular-searches": "Popular Searches", "graphs.page-views": "Wyświetlenia strony", "graphs.page-views-registered": "Wyświetlenia użytkowników", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Wyświetlenia botów", "graphs.unique-visitors": "Unikalni użytkownicy", "graphs.registered-users": "Zarejestrowani użytkownicy", - "graphs.anonymous-users": "Anonimowi użytkownicy", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Ostatnio restartowany przez", "no-users-browsing": "Brak przeglądających", diff --git a/public/language/pl/admin/menu.json b/public/language/pl/admin/menu.json index 8c38851bf7..55223f5f0e 100644 --- a/public/language/pl/admin/menu.json +++ b/public/language/pl/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Ogólne", "section-manage": "Zarządzanie", diff --git a/public/language/pt-BR/admin/dashboard.json b/public/language/pt-BR/admin/dashboard.json index 5769a80e97..8c7045e969 100644 --- a/public/language/pt-BR/admin/dashboard.json +++ b/public/language/pt-BR/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Conexões", - "anonymous-registered-users": "Anônimos vs Usuários Registrados", - "anonymous": "Anônimo", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registrado", "user-presence": "Presença de Usuário", @@ -68,6 +68,7 @@ "unread": "Não-lidos", "high-presence-topics": "Tópicos de Alta Participação", + "popular-searches": "Popular Searches", "graphs.page-views": "Páginas Visualizadas", "graphs.page-views-registered": "Páginas Visualizadas por Registrados", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Páginas Visualizadas por Bot", "graphs.unique-visitors": "Visitantes Únicos", "graphs.registered-users": "Usuários Registrados", - "graphs.anonymous-users": "Usuários Anônimos", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Última vez reiniciado por", "no-users-browsing": "Nenhum usuário navegando", diff --git a/public/language/pt-BR/admin/menu.json b/public/language/pt-BR/admin/menu.json index df133d872f..9e620cd716 100644 --- a/public/language/pt-BR/admin/menu.json +++ b/public/language/pt-BR/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Usuários", "dashboard/topics": "Tópicos", + "dashboard/searches": "Searches", "section-general": "Geral", "section-manage": "Administrar", diff --git a/public/language/pt-PT/admin/dashboard.json b/public/language/pt-PT/admin/dashboard.json index 737a8ef13b..dc114630fc 100644 --- a/public/language/pt-PT/admin/dashboard.json +++ b/public/language/pt-PT/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Conexões", - "anonymous-registered-users": "Utilizadores Anónimos vs Registados", - "anonymous": "Anónimos", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registados", "user-presence": "Presença dos Utilizadores", @@ -68,6 +68,7 @@ "unread": "Não lidos", "high-presence-topics": " Alta Presença em Tópicos", + "popular-searches": "Popular Searches", "graphs.page-views": "Visualizações de páginas", "graphs.page-views-registered": "Visualizações de páginas por utilizadores registados", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Visualizações de páginas por bots", "graphs.unique-visitors": "Visitantes únicos", "graphs.registered-users": "Utilizadores Registados", - "graphs.anonymous-users": "Utilizadores Anónimos", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Última vez reiniciado por", "no-users-browsing": "No users browsing", diff --git a/public/language/pt-PT/admin/menu.json b/public/language/pt-PT/admin/menu.json index 25d60dd92d..925af96d95 100644 --- a/public/language/pt-PT/admin/menu.json +++ b/public/language/pt-PT/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Geral", "section-manage": "Gerir", diff --git a/public/language/ro/admin/dashboard.json b/public/language/ro/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/ro/admin/dashboard.json +++ b/public/language/ro/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/ro/admin/menu.json b/public/language/ro/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/ro/admin/menu.json +++ b/public/language/ro/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/ru/admin/dashboard.json b/public/language/ru/admin/dashboard.json index 067bcae894..3e09e8bf00 100644 --- a/public/language/ru/admin/dashboard.json +++ b/public/language/ru/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Всего", "active-users.connections": "Соединений", - "anonymous-registered-users": "Анонимные / Авторизованные", - "anonymous": "Анонимные", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Авторизованные", "user-presence": "Присутствие", @@ -68,6 +68,7 @@ "unread": "Просм. непрочитанные", "high-presence-topics": "Популярные темы", + "popular-searches": "Popular Searches", "graphs.page-views": "Просмотры", "graphs.page-views-registered": "Просм. авторизованными", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Просмотров ботами", "graphs.unique-visitors": "Уникальных посетителей", "graphs.registered-users": "Авторизованных пользователей", - "graphs.anonymous-users": "Анонимных пользователей", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Последний перезапуск:", "no-users-browsing": "Просмотров нет", diff --git a/public/language/ru/admin/menu.json b/public/language/ru/admin/menu.json index 1cdfbb55d7..76f895e641 100644 --- a/public/language/ru/admin/menu.json +++ b/public/language/ru/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Авторизаций", "dashboard/users": "Пользователи", "dashboard/topics": "Темы", + "dashboard/searches": "Searches", "section-general": "Общие", "section-manage": "Управление", diff --git a/public/language/rw/admin/dashboard.json b/public/language/rw/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/rw/admin/dashboard.json +++ b/public/language/rw/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/rw/admin/menu.json b/public/language/rw/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/rw/admin/menu.json +++ b/public/language/rw/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/sc/admin/dashboard.json b/public/language/sc/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/sc/admin/dashboard.json +++ b/public/language/sc/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/sc/admin/menu.json b/public/language/sc/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/sc/admin/menu.json +++ b/public/language/sc/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/sk/admin/dashboard.json b/public/language/sk/admin/dashboard.json index 6fef088b74..761e1a06b9 100644 --- a/public/language/sk/admin/dashboard.json +++ b/public/language/sk/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Celkovo", "active-users.connections": "Pripojenia", - "anonymous-registered-users": "Anonymný vs zaregistrovaný používatelia", - "anonymous": "Anonymné", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Zaregistrovaný", "user-presence": "Výskyt používateľa", @@ -68,6 +68,7 @@ "unread": "Neprečitané", "high-presence-topics": "Témy s vysokou účasťou", + "popular-searches": "Popular Searches", "graphs.page-views": "Zobrazenia stránok", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unikátny navštevníci", "graphs.registered-users": "Zarestrovaný užívatelia", - "graphs.anonymous-users": "Neznámy užívatelia", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Posledná obnova od", "no-users-browsing": "Žiadni používatelia neprehliadajú", diff --git a/public/language/sk/admin/menu.json b/public/language/sk/admin/menu.json index a1f427f47c..12aa2962be 100644 --- a/public/language/sk/admin/menu.json +++ b/public/language/sk/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Všeobecné", "section-manage": "Spravovať", diff --git a/public/language/sl/admin/dashboard.json b/public/language/sl/admin/dashboard.json index 366af71742..7b9d750879 100644 --- a/public/language/sl/admin/dashboard.json +++ b/public/language/sl/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Skupaj", "active-users.connections": "Povezave", - "anonymous-registered-users": "Anonimni : Registrirani uporabniki", - "anonymous": "Anonimni", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registrirani", "user-presence": "Prisotnost uporabnikov", @@ -68,6 +68,7 @@ "unread": "Neprebrano", "high-presence-topics": "Teme z visoko prisotnostjo", + "popular-searches": "Popular Searches", "graphs.page-views": "Ogledov strani", "graphs.page-views-registered": "Ogledov strani-registrirani", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Ogledov strani-robot", "graphs.unique-visitors": "Edinstveni obiskovalci", "graphs.registered-users": "Registrirani uporabniki", - "graphs.anonymous-users": "Anonimni uporabniki", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Nazadnje ponovno zagnal(a)", "no-users-browsing": "Ne brska noben uporabnik", diff --git a/public/language/sl/admin/menu.json b/public/language/sl/admin/menu.json index e9734fac37..0484b96aee 100644 --- a/public/language/sl/admin/menu.json +++ b/public/language/sl/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Prijave", "dashboard/users": "Uporabniki", "dashboard/topics": "Teme", + "dashboard/searches": "Searches", "section-general": "Splošno", "section-manage": "Upravljaj", diff --git a/public/language/sr/admin/dashboard.json b/public/language/sr/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/sr/admin/dashboard.json +++ b/public/language/sr/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/sr/admin/menu.json b/public/language/sr/admin/menu.json index 9294dcad89..1b369a0fcd 100644 --- a/public/language/sr/admin/menu.json +++ b/public/language/sr/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Uopšteno", "section-manage": "Menadžment", diff --git a/public/language/sv/admin/dashboard.json b/public/language/sv/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/sv/admin/dashboard.json +++ b/public/language/sv/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/sv/admin/menu.json b/public/language/sv/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/sv/admin/menu.json +++ b/public/language/sv/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/th/admin/dashboard.json b/public/language/th/admin/dashboard.json index 0de31d4917..d864e385f8 100644 --- a/public/language/th/admin/dashboard.json +++ b/public/language/th/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connections", - "anonymous-registered-users": "Anonymous vs Registered Users", - "anonymous": "Anonymous", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Registered", "user-presence": "User Presence", @@ -68,6 +68,7 @@ "unread": "Unread", "high-presence-topics": "High Presence Topics", + "popular-searches": "Popular Searches", "graphs.page-views": "Page Views", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Unique Visitors", "graphs.registered-users": "Registered Users", - "graphs.anonymous-users": "Anonymous Users", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Last restarted by", "no-users-browsing": "No users browsing", diff --git a/public/language/th/admin/menu.json b/public/language/th/admin/menu.json index 1c5ea73b4f..5b22fbeb36 100644 --- a/public/language/th/admin/menu.json +++ b/public/language/th/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "General", "section-manage": "Manage", diff --git a/public/language/tr/admin/dashboard.json b/public/language/tr/admin/dashboard.json index 8634d80734..30b53e58e1 100644 --- a/public/language/tr/admin/dashboard.json +++ b/public/language/tr/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Genel Toplam", "active-users.connections": "Bağlantılar", - "anonymous-registered-users": "Anonim vs Kayıtlı Kullanıcılar", - "anonymous": "Anonim", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Kayıtlı", "user-presence": "Kullanıcı Durumları", @@ -68,6 +68,7 @@ "unread": "Okunmamış Konular Sayfasında", "high-presence-topics": "Öne Çıkan Başlıklar", + "popular-searches": "Popular Searches", "graphs.page-views": "Sayfa Gösterimi", "graphs.page-views-registered": "Kayıtlı Kullanıcıların Sayfa Gösterimi", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Bot Sayfa Gösterimi", "graphs.unique-visitors": "Benzersiz Ziyaretçiler", "graphs.registered-users": "Kayıtlı Kullanıcılar", - "graphs.anonymous-users": "Anonim Kullanıcılar", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Son yeniden başlatma bilgisi", "no-users-browsing": "İnceleyen kullanıcı yok", diff --git a/public/language/tr/admin/menu.json b/public/language/tr/admin/menu.json index c9ce2dc287..0d5e14bc14 100644 --- a/public/language/tr/admin/menu.json +++ b/public/language/tr/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Girişler", "dashboard/users": "Kullanıcılar", "dashboard/topics": "Başlıklar", + "dashboard/searches": "Searches", "section-general": "Genel", "section-manage": "Yönet", diff --git a/public/language/uk/admin/dashboard.json b/public/language/uk/admin/dashboard.json index 02416fb058..f42a1a6e2f 100644 --- a/public/language/uk/admin/dashboard.json +++ b/public/language/uk/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Разом", "active-users.connections": "З'єднання", - "anonymous-registered-users": "Аноніми проти Зареєстрованих", - "anonymous": "Аноніми", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Зареєстровані", "user-presence": "Присутність користувача", @@ -68,6 +68,7 @@ "unread": "Непрочитані", "high-presence-topics": "Теми з високою присутністю", + "popular-searches": "Popular Searches", "graphs.page-views": "Перегляди сторінок", "graphs.page-views-registered": "Page Views Registered", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Page Views Bot", "graphs.unique-visitors": "Унікальні відвідувачі", "graphs.registered-users": "Зареєстровані користувачі", - "graphs.anonymous-users": "Анонімні користувачі", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Останнє перезавантаження", "no-users-browsing": "Немає користувачів онлайн", diff --git a/public/language/uk/admin/menu.json b/public/language/uk/admin/menu.json index 4da4abf0fc..7dd7c875fb 100644 --- a/public/language/uk/admin/menu.json +++ b/public/language/uk/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "Загальні", "section-manage": "Керування", diff --git a/public/language/vi/admin/dashboard.json b/public/language/vi/admin/dashboard.json index 9b81d59690..a9e34051b2 100644 --- a/public/language/vi/admin/dashboard.json +++ b/public/language/vi/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Tổng", "active-users.connections": "Kết nối", - "anonymous-registered-users": "Người Dùng Ẩn Danh và Đã Đăng Ký", - "anonymous": "Ẩn Danh", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "Đã đăng ký", "user-presence": "Người Dùng Có Mặt", @@ -68,6 +68,7 @@ "unread": "Chưa đọc", "high-presence-topics": "Chủ Đề Hiện Diện Cao", + "popular-searches": "Popular Searches", "graphs.page-views": "Xem Trang", "graphs.page-views-registered": "Đã Đăng Ký Xem Trang", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "Bot Xem Trang", "graphs.unique-visitors": "Khách Truy Cập Duy Nhất", "graphs.registered-users": "Thành Viên Chính Thức", - "graphs.anonymous-users": "Người Dùng Ẩn Danh", + "graphs.guest-users": "Guest Users", "last-restarted-by": "Khởi động lại lần cuối bởi", "no-users-browsing": "Người không xem bài", diff --git a/public/language/vi/admin/menu.json b/public/language/vi/admin/menu.json index c983024553..2e71acff00 100644 --- a/public/language/vi/admin/menu.json +++ b/public/language/vi/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Đăng nhập", "dashboard/users": "Người dùng", "dashboard/topics": "Chủ đề", + "dashboard/searches": "Searches", "section-general": "Chung", "section-manage": "Quản lý", diff --git a/public/language/zh-CN/admin/dashboard.json b/public/language/zh-CN/admin/dashboard.json index 427fdb412a..1ab9d1eafb 100644 --- a/public/language/zh-CN/admin/dashboard.json +++ b/public/language/zh-CN/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "全部", "active-users.connections": "连接", - "anonymous-registered-users": "匿名 vs 注册用户", - "anonymous": "匿名", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "已注册", "user-presence": "用户光临", @@ -68,6 +68,7 @@ "unread": "未读", "high-presence-topics": "热门话题", + "popular-searches": "Popular Searches", "graphs.page-views": "页面浏览量", "graphs.page-views-registered": "注册用户页面浏览量", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "爬虫页面浏览量", "graphs.unique-visitors": "单一访客", "graphs.registered-users": "已注册用户", - "graphs.anonymous-users": "匿名用户", + "graphs.guest-users": "Guest Users", "last-restarted-by": "上次重启管理员/时间", "no-users-browsing": "没有用户正在浏览", diff --git a/public/language/zh-CN/admin/menu.json b/public/language/zh-CN/admin/menu.json index 283c64c2f6..cc413ef8b3 100644 --- a/public/language/zh-CN/admin/menu.json +++ b/public/language/zh-CN/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "登录", "dashboard/users": "用户", "dashboard/topics": "主题", + "dashboard/searches": "Searches", "section-general": "基本", "section-manage": "管理", diff --git a/public/language/zh-TW/admin/dashboard.json b/public/language/zh-TW/admin/dashboard.json index 90adfc831a..fe7a57727d 100644 --- a/public/language/zh-TW/admin/dashboard.json +++ b/public/language/zh-TW/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "全部", "active-users.connections": "連線", - "anonymous-registered-users": "匿名 vs 註冊使用者", - "anonymous": "匿名", + "guest-registered-users": "Guest vs Registered Users", + "guest": "Guest", "registered": "已註冊", "user-presence": "使用者光臨", @@ -68,6 +68,7 @@ "unread": "未讀", "high-presence-topics": "熱門主題", + "popular-searches": "Popular Searches", "graphs.page-views": "頁面瀏覽量", "graphs.page-views-registered": "註冊使用者頁面瀏覽量", @@ -75,7 +76,7 @@ "graphs.page-views-bot": "爬蟲頁面瀏覽量", "graphs.unique-visitors": "不重複訪客", "graphs.registered-users": "已註冊使用者", - "graphs.anonymous-users": "匿名使用者", + "graphs.guest-users": "Guest Users", "last-restarted-by": "上次重啟管理員/時間", "no-users-browsing": "沒有使用者正在瀏覽", diff --git a/public/language/zh-TW/admin/menu.json b/public/language/zh-TW/admin/menu.json index 77c408d4be..22213c257f 100644 --- a/public/language/zh-TW/admin/menu.json +++ b/public/language/zh-TW/admin/menu.json @@ -4,6 +4,7 @@ "dashboard/logins": "Logins", "dashboard/users": "Users", "dashboard/topics": "Topics", + "dashboard/searches": "Searches", "section-general": "基本", "section-manage": "管理", From ee8e048015576a81b96df6fe57cd4308df24c5b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 16:32:35 -0400 Subject: [PATCH 275/412] fix: move record to controller --- src/controllers/search.js | 9 +++++++++ src/search.js | 8 -------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/controllers/search.js b/src/controllers/search.js index 0dbdff2dd0..d45a7fbe47 100644 --- a/src/controllers/search.js +++ b/src/controllers/search.js @@ -66,6 +66,7 @@ searchController.search = async function (req, res, next) { const [searchData, categoriesData] = await Promise.all([ search.search(data), + recordSearch(data); buildCategories(req.uid, searchOnly), ]); @@ -95,6 +96,14 @@ searchController.search = async function (req, res, next) { res.render('search', searchData); }; +async function recordSearch(data) { + const { query, searchIn } = data; + const cleanedQuery = String(query).trim().toLowerCase().substr(0, 255); + if (['titles', 'titlesposts', 'posts'].includes(searchIn) && cleanedQuery.length > 2) { + await db.sortedSetIncrBy('searches:all', 1, cleanedQuery); + } +} + async function buildCategories(uid, searchOnly) { if (searchOnly) { return []; diff --git a/src/search.js b/src/search.js index f54181fb52..99fae633e8 100644 --- a/src/search.js +++ b/src/search.js @@ -45,7 +45,6 @@ async function searchInContent(data) { async function doSearch(type, searchIn) { if (searchIn.includes(data.searchIn)) { - await recordSearch(data.query); return await plugins.hooks.fire('filter:search.query', { index: type, content: data.query, @@ -95,13 +94,6 @@ async function searchInContent(data) { return Object.assign(returnData, metadata); } -async function recordSearch(query) { - const cleanedQuery = String(query).trim().toLowerCase().substr(0, 255); - if (cleanedQuery.length > 2) { - await db.sortedSetIncrBy('searches:all', 1, cleanedQuery); - } -} - async function filterAndSort(pids, data) { if (data.sortBy === 'relevance' && !data.replies && !data.timeRange && !data.hasTags && !plugins.hooks.hasListeners('filter:search.filterAndSort')) { return pids; From a5287906151cf9a54bcc04b347592aeb2954e9e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 16:34:24 -0400 Subject: [PATCH 276/412] refactor: typo --- src/controllers/search.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/controllers/search.js b/src/controllers/search.js index d45a7fbe47..e3d9304dd7 100644 --- a/src/controllers/search.js +++ b/src/controllers/search.js @@ -3,6 +3,7 @@ const validator = require('validator'); +const db = require('../database'); const meta = require('../meta'); const plugins = require('../plugins'); const search = require('../search'); @@ -66,7 +67,7 @@ searchController.search = async function (req, res, next) { const [searchData, categoriesData] = await Promise.all([ search.search(data), - recordSearch(data); + recordSearch(data), buildCategories(req.uid, searchOnly), ]); From eb075c7328f07f839ee4d887eced6839477390fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 16:35:37 -0400 Subject: [PATCH 277/412] fix: add missing translation --- public/language/en-GB/admin/dashboard.json | 1 + 1 file changed, 1 insertion(+) diff --git a/public/language/en-GB/admin/dashboard.json b/public/language/en-GB/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/en-GB/admin/dashboard.json +++ b/public/language/en-GB/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" From ff962b5ddf2c14cde6e6c8bc9ce13636d7e459cf Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Mon, 25 Oct 2021 20:36:22 +0000 Subject: [PATCH 278/412] chore(i18n): fallback strings for new resources: nodebb.admin-dashboard --- public/language/ar/admin/dashboard.json | 1 + public/language/bg/admin/dashboard.json | 1 + public/language/bn/admin/dashboard.json | 1 + public/language/cs/admin/dashboard.json | 1 + public/language/da/admin/dashboard.json | 1 + public/language/de/admin/dashboard.json | 1 + public/language/el/admin/dashboard.json | 1 + public/language/en-US/admin/dashboard.json | 1 + public/language/en-x-pirate/admin/dashboard.json | 1 + public/language/es/admin/dashboard.json | 1 + public/language/et/admin/dashboard.json | 1 + public/language/fa-IR/admin/dashboard.json | 1 + public/language/fi/admin/dashboard.json | 1 + public/language/fr/admin/dashboard.json | 1 + public/language/gl/admin/dashboard.json | 1 + public/language/he/admin/dashboard.json | 1 + public/language/hr/admin/dashboard.json | 1 + public/language/hu/admin/dashboard.json | 1 + public/language/id/admin/dashboard.json | 1 + public/language/it/admin/dashboard.json | 1 + public/language/ja/admin/dashboard.json | 1 + public/language/ko/admin/dashboard.json | 1 + public/language/lt/admin/dashboard.json | 1 + public/language/lv/admin/dashboard.json | 1 + public/language/ms/admin/dashboard.json | 1 + public/language/nb/admin/dashboard.json | 1 + public/language/nl/admin/dashboard.json | 1 + public/language/pl/admin/dashboard.json | 1 + public/language/pt-BR/admin/dashboard.json | 1 + public/language/pt-PT/admin/dashboard.json | 1 + public/language/ro/admin/dashboard.json | 1 + public/language/ru/admin/dashboard.json | 1 + public/language/rw/admin/dashboard.json | 1 + public/language/sc/admin/dashboard.json | 1 + public/language/sk/admin/dashboard.json | 1 + public/language/sl/admin/dashboard.json | 1 + public/language/sr/admin/dashboard.json | 1 + public/language/sv/admin/dashboard.json | 1 + public/language/th/admin/dashboard.json | 1 + public/language/tr/admin/dashboard.json | 1 + public/language/uk/admin/dashboard.json | 1 + public/language/vi/admin/dashboard.json | 1 + public/language/zh-CN/admin/dashboard.json | 1 + public/language/zh-TW/admin/dashboard.json | 1 + 44 files changed, 44 insertions(+) diff --git a/public/language/ar/admin/dashboard.json b/public/language/ar/admin/dashboard.json index b2a50f73de..a54c39d931 100644 --- a/public/language/ar/admin/dashboard.json +++ b/public/language/ar/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/bg/admin/dashboard.json b/public/language/bg/admin/dashboard.json index 1a7eb1ff43..4d5e2ea156 100644 --- a/public/language/bg/admin/dashboard.json +++ b/public/language/bg/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Назад към таблото", "details.no-users": "В избрания период не са се регистрирали нови потребители", "details.no-topics": "В избрания период не са публикувани нови теми", + "details.no-searches": "No searches have been made yet", "details.no-logins": "В избрания период не са отчетени вписвания", "details.logins-static": "NodeBB запазва данни за сесията в продължение на %1 дни, така че в следната таблица могат да се видят само последните активни сесии", "details.logins-login-time": "Време на вписване" diff --git a/public/language/bn/admin/dashboard.json b/public/language/bn/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/bn/admin/dashboard.json +++ b/public/language/bn/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/cs/admin/dashboard.json b/public/language/cs/admin/dashboard.json index 637e35752e..2ca82e2cce 100644 --- a/public/language/cs/admin/dashboard.json +++ b/public/language/cs/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/da/admin/dashboard.json b/public/language/da/admin/dashboard.json index 32a61894e5..1d7c3df85d 100644 --- a/public/language/da/admin/dashboard.json +++ b/public/language/da/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/de/admin/dashboard.json b/public/language/de/admin/dashboard.json index f3c744c715..5b4bcf4bf5 100644 --- a/public/language/de/admin/dashboard.json +++ b/public/language/de/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Zurück zur Übersicht", "details.no-users": "Keine Benutzer sind im gewählten Zeitraum beigetreten", "details.no-topics": "Keine Themen wurden im gewählten Zeitraum beigetreten", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Keine Logins wurden im gewählten Zeitraum festgestellt", "details.logins-static": "NodeBB speichert Sitzungsdaten nur für %1 Tage, deshalb zeigt die untere Tabelle nur die neuesten, aktiven Sitzungen", "details.logins-login-time": "Anmelde Zeit" diff --git a/public/language/el/admin/dashboard.json b/public/language/el/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/el/admin/dashboard.json +++ b/public/language/el/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/en-US/admin/dashboard.json b/public/language/en-US/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/en-US/admin/dashboard.json +++ b/public/language/en-US/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/en-x-pirate/admin/dashboard.json b/public/language/en-x-pirate/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/en-x-pirate/admin/dashboard.json +++ b/public/language/en-x-pirate/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/es/admin/dashboard.json b/public/language/es/admin/dashboard.json index d8b98fbb7e..a1d11fab48 100644 --- a/public/language/es/admin/dashboard.json +++ b/public/language/es/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/et/admin/dashboard.json b/public/language/et/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/et/admin/dashboard.json +++ b/public/language/et/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/fa-IR/admin/dashboard.json b/public/language/fa-IR/admin/dashboard.json index e82461d99b..7952eee216 100644 --- a/public/language/fa-IR/admin/dashboard.json +++ b/public/language/fa-IR/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/fi/admin/dashboard.json b/public/language/fi/admin/dashboard.json index 856db27e90..2fa46e3a70 100644 --- a/public/language/fi/admin/dashboard.json +++ b/public/language/fi/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Takaisin ohjausnäkymään", "details.no-users": "Ei liittyneitä käyttäjiä valitulla aikavälillä.", "details.no-topics": "Ei luotuja aiheita valitulla aikavälillä.", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Ei sisäänkirjautumisia valitulla aikavälillä.", "details.logins-static": "NodeBB tallettaa istuntotiedot vain %1 päivän ajaksi, joten tämä kuvaaja näyttää vain viimeisimpänä aktiivisena olleet istunnot.", "details.logins-login-time": "Sisäänkirjautumisaika" diff --git a/public/language/fr/admin/dashboard.json b/public/language/fr/admin/dashboard.json index 411890f7de..3a4f7bf284 100644 --- a/public/language/fr/admin/dashboard.json +++ b/public/language/fr/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Retour au Tableau de bord", "details.no-users": "Aucun utilisateur ne s'est joint dans le délai sélectionné", "details.no-topics": "Aucun sujet n'a été publié dans la période sélectionnée", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Aucune connexion n'a été enregistrée dans le délai sélectionné", "details.logins-static": "NodeBB n'enregistre que les données de session pendant %1 jours, et le tableau ci-dessous n'affichera donc que les dernières sessions actives", "details.logins-login-time": "Heure de connexion" diff --git a/public/language/gl/admin/dashboard.json b/public/language/gl/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/gl/admin/dashboard.json +++ b/public/language/gl/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/he/admin/dashboard.json b/public/language/he/admin/dashboard.json index 887fd70646..0b9b6e20a6 100644 --- a/public/language/he/admin/dashboard.json +++ b/public/language/he/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "חזרה ללוח מחוונים", "details.no-users": "אין משתמש שהצטרף במסגרת הזמן שנבחרה", "details.no-topics": "לא פורסמו נושאים במסגרת הזמן שנבחרה", + "details.no-searches": "No searches have been made yet", "details.no-logins": "לא נרשמו כניסות במסגרת הזמן שנבחרה", "details.logins-static": "NodeBB שומר נתוני הפעלה עבור %1 ימים בלבד, ולכן טבלה זו תציג רק את הכניסות הפעילות האחרונות", "details.logins-login-time": "זמן כניסה" diff --git a/public/language/hr/admin/dashboard.json b/public/language/hr/admin/dashboard.json index a44e4d70be..8072389569 100644 --- a/public/language/hr/admin/dashboard.json +++ b/public/language/hr/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/hu/admin/dashboard.json b/public/language/hu/admin/dashboard.json index 6d446490ee..e02ccff6de 100644 --- a/public/language/hu/admin/dashboard.json +++ b/public/language/hu/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Vissza a vezérlőpultra", "details.no-users": "Nem csatlakozott egy felhasználó sem a kiválasztott időszakban", "details.no-topics": "Nem voltak új témakörök a kiválasztott időszakban", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Nem volt bejelentkezés a kiválasztott időszakban", "details.logins-static": "A NodeBB csak %1 napig menti a munkamenet adatokat és az alábbi táblázat csak a legutóbbi aktív munkameneteket tartalmazza", "details.logins-login-time": "Bejelentkezés ideje" diff --git a/public/language/id/admin/dashboard.json b/public/language/id/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/id/admin/dashboard.json +++ b/public/language/id/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/it/admin/dashboard.json b/public/language/it/admin/dashboard.json index 9947c2b5fd..9a3dca1426 100644 --- a/public/language/it/admin/dashboard.json +++ b/public/language/it/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Torna alla dashboard", "details.no-users": "Nessun utente si è iscritto nell'arco di tempo selezionato", "details.no-topics": "Nessuna discussione è stata postata nell'arco di tempo selezionato", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Non sono stati registrati accessi nell'arco di tempo selezionato", "details.logins-static": "NodeBB salva solo i dati di sessione per %1 giorni, quindi la tabella qui sotto mostrerà solo le sessioni attive più recenti", "details.logins-login-time": "Tempo di accesso" diff --git a/public/language/ja/admin/dashboard.json b/public/language/ja/admin/dashboard.json index f6cbb54b4a..b21cbb4cc2 100644 --- a/public/language/ja/admin/dashboard.json +++ b/public/language/ja/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/ko/admin/dashboard.json b/public/language/ko/admin/dashboard.json index dcc6afa567..aee85929ae 100644 --- a/public/language/ko/admin/dashboard.json +++ b/public/language/ko/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "대시보드로 돌아가기", "details.no-users": "설정한 기간에 가입한 사용자 없음", "details.no-topics": "설정한 기간에 생성된 화제 없음", + "details.no-searches": "No searches have been made yet", "details.no-logins": "설정한 기간에 로그인 기록 없음", "details.logins-static": "NodeBB는 세션 정보를 %1일 동안만 저장합니다. 따라서 아래의 표는 최근 활성화된 세션 정보만을 표시합니다.", "details.logins-login-time": "로그인 시점" diff --git a/public/language/lt/admin/dashboard.json b/public/language/lt/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/lt/admin/dashboard.json +++ b/public/language/lt/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/lv/admin/dashboard.json b/public/language/lv/admin/dashboard.json index 698fe8392c..076694b4ca 100644 --- a/public/language/lv/admin/dashboard.json +++ b/public/language/lv/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/ms/admin/dashboard.json b/public/language/ms/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/ms/admin/dashboard.json +++ b/public/language/ms/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/nb/admin/dashboard.json b/public/language/nb/admin/dashboard.json index 73f19422c9..112aa9389e 100644 --- a/public/language/nb/admin/dashboard.json +++ b/public/language/nb/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/nl/admin/dashboard.json b/public/language/nl/admin/dashboard.json index d18af4cb65..2acaa26a6a 100644 --- a/public/language/nl/admin/dashboard.json +++ b/public/language/nl/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/pl/admin/dashboard.json b/public/language/pl/admin/dashboard.json index 8b7d92b6e3..ba2aed1b4d 100644 --- a/public/language/pl/admin/dashboard.json +++ b/public/language/pl/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Powrót do Dashboardu", "details.no-users": "Żaden użytkownik nie dołączył w wybranym okresie", "details.no-topics": "Żadne tematy nie zostały opublikowane w wybranym okresie", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Żadne logi nie zostały zapisane w wybranym okresie", "details.logins-static": "NodeBB zapisuje dane sesji tylko na %1 dzień, dlatego tabela poniżej zawierać będzie tylko ostatnią aktywną sesję", "details.logins-login-time": "Czas logowania" diff --git a/public/language/pt-BR/admin/dashboard.json b/public/language/pt-BR/admin/dashboard.json index 8c7045e969..e59eb05ad1 100644 --- a/public/language/pt-BR/admin/dashboard.json +++ b/public/language/pt-BR/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "De volta ao Painel", "details.no-users": "Nenhum usuário ingressou dentro do período de tempo selecionado", "details.no-topics": "Nenhum tópico foi postado dentro do período de tempo selecionado", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Nenhum login foi registrado dentro do período de tempo selecionado", "details.logins-static": "O NodeBB só salva os dados da sessão por %1 dias, então esta tabela abaixo mostrará apenas as sessões ativas mais recentemente", "details.logins-login-time": "Hora de Login" diff --git a/public/language/pt-PT/admin/dashboard.json b/public/language/pt-PT/admin/dashboard.json index dc114630fc..9f590b49c2 100644 --- a/public/language/pt-PT/admin/dashboard.json +++ b/public/language/pt-PT/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/ro/admin/dashboard.json b/public/language/ro/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/ro/admin/dashboard.json +++ b/public/language/ro/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/ru/admin/dashboard.json b/public/language/ru/admin/dashboard.json index 3e09e8bf00..f8e093c304 100644 --- a/public/language/ru/admin/dashboard.json +++ b/public/language/ru/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Вернуться на Панель управления", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/rw/admin/dashboard.json b/public/language/rw/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/rw/admin/dashboard.json +++ b/public/language/rw/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/sc/admin/dashboard.json b/public/language/sc/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/sc/admin/dashboard.json +++ b/public/language/sc/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/sk/admin/dashboard.json b/public/language/sk/admin/dashboard.json index 761e1a06b9..b1c6670e81 100644 --- a/public/language/sk/admin/dashboard.json +++ b/public/language/sk/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/sl/admin/dashboard.json b/public/language/sl/admin/dashboard.json index 7b9d750879..9f7b21b93a 100644 --- a/public/language/sl/admin/dashboard.json +++ b/public/language/sl/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Nazaj na nadzorno ploščo", "details.no-users": "V izbranem časovnem okviru se ni pridružil noben uporabnik", "details.no-topics": "V izbranem časovnem okviru ni bila objavljena nobena tema", + "details.no-searches": "No searches have been made yet", "details.no-logins": "V izbranem časovnem okviru ni bila zabeležena nobena prijava", "details.logins-static": "NodeBB shranjuje samo podatke o sejah za %1 dni, zato bo ta spodnja tabela prikazala samo zadnje aktivne seje", "details.logins-login-time": "Čas prijave" diff --git a/public/language/sr/admin/dashboard.json b/public/language/sr/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/sr/admin/dashboard.json +++ b/public/language/sr/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/sv/admin/dashboard.json b/public/language/sv/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/sv/admin/dashboard.json +++ b/public/language/sv/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/th/admin/dashboard.json b/public/language/th/admin/dashboard.json index d864e385f8..4d39626882 100644 --- a/public/language/th/admin/dashboard.json +++ b/public/language/th/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/tr/admin/dashboard.json b/public/language/tr/admin/dashboard.json index 30b53e58e1..132f58a29a 100644 --- a/public/language/tr/admin/dashboard.json +++ b/public/language/tr/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Yönetim Paneline geri dön", "details.no-users": "Seçilen zaman aralığında herhangi bir kullanıcı üye olmadı.", "details.no-topics": "Seçilen zaman aralığında herhangi bir başlık oluşturulmadı. ", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Seçilen zaman aralığında herhangi bir giriş yapılmadı.", "details.logins-static": "NodeBB oturum kayıtlarını sadece %1 gün tutar, o nedenle aşağıdaki tablo sadece en yakın aktif oturumları listeler", "details.logins-login-time": "Giriş zamanı" diff --git a/public/language/uk/admin/dashboard.json b/public/language/uk/admin/dashboard.json index f42a1a6e2f..62eee08e51 100644 --- a/public/language/uk/admin/dashboard.json +++ b/public/language/uk/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Back to Dashboard", "details.no-users": "No users have joined within the selected timeframe", "details.no-topics": "No topics have been posted within the selected timeframe", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "Login Time" diff --git a/public/language/vi/admin/dashboard.json b/public/language/vi/admin/dashboard.json index a9e34051b2..a3d4dc5c28 100644 --- a/public/language/vi/admin/dashboard.json +++ b/public/language/vi/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "Quay lại Bảng điều khiển", "details.no-users": "Không có người dùng nào tham gia trong khung thời gian đã chọn", "details.no-topics": "Không có chủ đề nào được đăng trong khung thời gian đã chọn", + "details.no-searches": "No searches have been made yet", "details.no-logins": "Không có thông tin đăng nhập nào được ghi lại trong khung thời gian đã chọn", "details.logins-static": "NodeBB chỉ lưu dữ liệu phiên trong %1 ngày và do đó, bảng này bên dưới sẽ chỉ hiển thị các phiên hoạt động gần đây nhất", "details.logins-login-time": "Thời gian đăng nhập" diff --git a/public/language/zh-CN/admin/dashboard.json b/public/language/zh-CN/admin/dashboard.json index 1ab9d1eafb..28a008851f 100644 --- a/public/language/zh-CN/admin/dashboard.json +++ b/public/language/zh-CN/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "返回控制面板", "details.no-users": "选定的时间内没有用户加入", "details.no-topics": "选定的时间内没有发布主题", + "details.no-searches": "No searches have been made yet", "details.no-logins": "选定的时间内没有登录记录", "details.logins-static": "NodeBB只保留%1天登录数据,下列表格显示最近活动的登录。", "details.logins-login-time": "登录时间" diff --git a/public/language/zh-TW/admin/dashboard.json b/public/language/zh-TW/admin/dashboard.json index fe7a57727d..4b9601493e 100644 --- a/public/language/zh-TW/admin/dashboard.json +++ b/public/language/zh-TW/admin/dashboard.json @@ -83,6 +83,7 @@ "back-to-dashboard": "回到儀表板", "details.no-users": "沒有使用者有在選定的時間內註冊", "details.no-topics": "沒有新增的主題在選定的時間內", + "details.no-searches": "No searches have been made yet", "details.no-logins": "No logins have been recorded within the selected timeframe", "details.logins-static": "NodeBB only saves session data for %1 days, and so this table below will only show the most recently active sessions", "details.logins-login-time": "登入時間" From da64810a4a87260a2d5dfd032b934eb0d1b69748 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 16:37:36 -0400 Subject: [PATCH 279/412] fix: crash --- src/controllers/search.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/search.js b/src/controllers/search.js index e3d9304dd7..906277f8ba 100644 --- a/src/controllers/search.js +++ b/src/controllers/search.js @@ -67,8 +67,8 @@ searchController.search = async function (req, res, next) { const [searchData, categoriesData] = await Promise.all([ search.search(data), - recordSearch(data), buildCategories(req.uid, searchOnly), + recordSearch(data), ]); searchData.pagination = pagination.create(page, searchData.pageCount, req.query); From 0926ae6ecf28390cc3dd31f51af59c716ec618f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 20:47:10 -0400 Subject: [PATCH 280/412] fix: api session revoke test --- src/controllers/errors.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/controllers/errors.js b/src/controllers/errors.js index 5677b66007..58f12d9f98 100644 --- a/src/controllers/errors.js +++ b/src/controllers/errors.js @@ -49,6 +49,9 @@ exports.handleErrors = async function handleErrors(err, req, res, next) { // esl }, }; const defaultHandler = async function () { + if (res.headersSent) { + return; + } // Display NodeBB error page const status = parseInt(err.status, 10); if ((status === 302 || status === 308) && err.path) { From 19ee717444da35374cb9c7d6677c78a0a6c6fc62 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 21:22:44 -0400 Subject: [PATCH 281/412] refactor: slowdown quick search --- public/src/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/app.js b/public/src/app.js index 0881a96839..34693e450f 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -575,7 +575,7 @@ app.cacheBuster = null; return quickSearchResults.addClass('hidden'); } doSearch(); - }, 250)); + }, 500)); let mousedownOnResults = false; quickSearchResults.on('mousedown', function () { From 89f5e06bbf84a9b19dca7f2dcefd38ebb2ecc412 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 22:03:59 -0400 Subject: [PATCH 282/412] fix: don't repeat search if on same page --- public/src/app.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/public/src/app.js b/public/src/app.js index 34693e450f..f6e93dfc92 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -590,12 +590,23 @@ app.cacheBuster = null; } }); + let ajaxified = false; + hooks.on('action:ajaxify.end', function () { + if (!ajaxify.isCold()) { + ajaxified = true; + } + }); inputEl.on('focus', function () { mousedownOnResults = false; oldValue = inputEl.val(); if (inputEl.val() && quickSearchResults.find('#quick-search-results').children().length) { updateCategoryFilterName(); - doSearch(); + if (ajaxified) { + doSearch(); + ajaxified = false; + } else { + quickSearchResults.removeClass('hidden'); + } inputEl[0].setSelectionRange(0, inputEl.val().length); } }); From 6cfaea06f03c04676c86e847bcc27fcb7c032af9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 22:06:28 -0400 Subject: [PATCH 283/412] fix: undefined query showing in searches --- src/controllers/search.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/controllers/search.js b/src/controllers/search.js index 906277f8ba..76a34d1e39 100644 --- a/src/controllers/search.js +++ b/src/controllers/search.js @@ -99,9 +99,11 @@ searchController.search = async function (req, res, next) { async function recordSearch(data) { const { query, searchIn } = data; - const cleanedQuery = String(query).trim().toLowerCase().substr(0, 255); - if (['titles', 'titlesposts', 'posts'].includes(searchIn) && cleanedQuery.length > 2) { - await db.sortedSetIncrBy('searches:all', 1, cleanedQuery); + if (query) { + const cleanedQuery = String(query).trim().toLowerCase().substr(0, 255); + if (['titles', 'titlesposts', 'posts'].includes(searchIn) && cleanedQuery.length > 2) { + await db.sortedSetIncrBy('searches:all', 1, cleanedQuery); + } } } From 64192731a0144c727340bbc6d111d55d7012bf9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 25 Oct 2021 23:12:34 -0400 Subject: [PATCH 284/412] refactor: use search api for topic search --- public/src/app.js | 13 ++-- public/src/client/topic.js | 7 +-- public/src/modules/search.js | 112 +---------------------------------- src/search.js | 17 ++++-- src/socket.io/topics.js | 1 + 5 files changed, 27 insertions(+), 123 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index f6e93dfc92..14e45d2794 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -531,7 +531,8 @@ app.cacheBuster = null; } data.posts.forEach(function (p) { const text = $('
    ' + p.content + '
    ').text(); - const start = Math.max(0, text.toLowerCase().indexOf(inputEl.val().toLowerCase()) - 40); + const query = inputEl.val().toLowerCase().replace(/^in:topic-\d+/, ''); + const start = Math.max(0, text.toLowerCase().indexOf(query) - 40); p.snippet = utils.escapeHTML((start > 0 ? '...' : '') + text.slice(start, start + 80) + (text.length - start > 80 ? '...' : '')); @@ -598,8 +599,9 @@ app.cacheBuster = null; }); inputEl.on('focus', function () { mousedownOnResults = false; - oldValue = inputEl.val(); - if (inputEl.val() && quickSearchResults.find('#quick-search-results').children().length) { + const query = inputEl.val(); + oldValue = query; + if (query && quickSearchResults.find('#quick-search-results').children().length) { updateCategoryFilterName(); if (ajaxified) { doSearch(); @@ -607,7 +609,10 @@ app.cacheBuster = null; } else { quickSearchResults.removeClass('hidden'); } - inputEl[0].setSelectionRange(0, inputEl.val().length); + inputEl[0].setSelectionRange( + query.startsWith('in:topic') ? query.indexOf(' ') + 1 : 0, + query.length + ); } }); diff --git a/public/src/client/topic.js b/public/src/client/topic.js index edba451ae9..bc0a340be3 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -95,12 +95,9 @@ define('forum/topic', [ if (config.topicSearchEnabled) { require(['mousetrap'], function (mousetrap) { mousetrap.bind(['command+f', 'ctrl+f'], function (e) { - const match = ajaxify.currentPage.match(/^topic\/([\d]+)/); - let tid; - if (match) { + if (ajaxify.data.template.topic) { e.preventDefault(); - tid = match[1]; - $('#search-fields input').val('in:topic-' + tid + ' '); + $('#search-fields input').val('in:topic-' + ajaxify.data.tid + ' '); app.prepareSearch(); } }); diff --git a/public/src/modules/search.js b/public/src/modules/search.js index a9e3625e9d..cd53fac2e9 100644 --- a/public/src/modules/search.js +++ b/public/src/modules/search.js @@ -7,20 +7,9 @@ define('search', ['navigator', 'translator', 'storage', 'hooks'], function (nav, }; Search.query = function (data, callback) { - // Detect if a tid was specified - const topicSearch = data.term.match(/^in:topic-([\d]+) /); callback = callback || function () {}; - if (!topicSearch) { - ajaxify.go('search?' + createQueryString(data)); - callback(); - } else { - const cleanedTerm = data.term.replace(topicSearch[0], ''); - const tid = topicSearch[1]; - - if (cleanedTerm.length > 0) { - Search.queryTopic(tid, cleanedTerm, callback); - } - } + ajaxify.go('search?' + createQueryString(data)); + callback(); }; Search.api = function (data, callback) { @@ -139,102 +128,5 @@ define('search', ['navigator', 'translator', 'storage', 'hooks'], function (nav, $('.search-result-text').find('img:not(.not-responsive)').addClass('img-responsive'); }; - Search.queryTopic = function (tid, term) { - socket.emit('topics.search', { - tid: tid, - term: term, - }, function (err, pids) { - if (err) { - return app.alertError(err.message); - } - - if (Array.isArray(pids)) { - // Sort pids numerically & store - Search.current = { - results: pids.sort(function (a, b) { - return a - b; - }), - tid: tid, - term: term, - }; - - Search.checkPagePresence(tid, function () { - Search.topicDOM.update(0); - }); - } - }); - }; - - Search.checkPagePresence = function (tid, callback) { - if (parseInt(ajaxify.data.tid, 10) !== parseInt(tid, 10)) { - ajaxify.go('topic/' + tid, callback); - } else { - callback(); - } - }; - - Search.topicDOM = { - active: false, - }; - - Search.topicDOM.prev = function () { - Search.topicDOM.update((Search.current.index === 0) ? Search.current.results.length - 1 : Search.current.index - 1); - }; - - Search.topicDOM.next = function () { - Search.topicDOM.update((Search.current.index === Search.current.results.length - 1) ? 0 : Search.current.index + 1); - }; - - Search.topicDOM.update = function (index) { - const topicSearchEl = $('.topic-search'); - Search.current.index = index; - - Search.topicDOM.start(); - - if (Search.current.results.length > 0) { - topicSearchEl.find('.count').html((index + 1) + ' / ' + Search.current.results.length); - topicSearchEl.find('.prev, .next').removeAttr('disabled'); - const data = { - pid: Search.current.results[index], - tid: Search.current.tid, - topicPostSort: config.topicPostSort, - }; - socket.emit('posts.getPidIndex', data, function (err, postIndex) { - if (err) { - return app.alertError(err.message); - } - - nav.scrollToIndex(postIndex, true); - }); - } else { - translator.translate('[[search:no-matches]]', function (text) { - topicSearchEl.find('.count').html(text); - }); - topicSearchEl.removeClass('hidden').find('.prev, .next').attr('disabled', 'disabled'); - } - }; - - Search.topicDOM.start = function () { - $('.topic-search').removeClass('hidden'); - if (!Search.topicDOM.active) { - Search.topicDOM.active = true; - - // Bind to esc - require(['mousetrap'], function (mousetrap) { - mousetrap.bind('esc', Search.topicDOM.end); - }); - } - }; - - Search.topicDOM.end = function () { - $('.topic-search').addClass('hidden').find('.prev, .next').attr('disabled', 'disabled'); - Search.topicDOM.active = false; - - // Unbind esc - require(['mousetrap'], function (mousetrap) { - mousetrap.unbind('esc', Search.topicDOM.end); - }); - }; - return Search; }); diff --git a/src/search.js b/src/search.js index 99fae633e8..e336031e45 100644 --- a/src/search.js +++ b/src/search.js @@ -56,10 +56,19 @@ async function searchInContent(data) { } return []; } - const [pids, tids] = await Promise.all([ - doSearch('post', ['posts', 'titlesposts']), - doSearch('topic', ['titles', 'titlesposts']), - ]); + let pids = []; + let tids = []; + const inTopic = data.query.match(/^in:topic-([\d]+) /); + if (inTopic) { + const tid = inTopic[1]; + const cleanedTerm = data.query.replace(inTopic[0], ''); + pids = await topics.search(tid, cleanedTerm); + } else { + [pids, tids] = await Promise.all([ + doSearch('post', ['posts', 'titlesposts']), + doSearch('topic', ['titles', 'titlesposts']), + ]); + } if (data.returnIds) { return { pids: pids, tids: tids }; diff --git a/src/socket.io/topics.js b/src/socket.io/topics.js index de4d356ad6..a60c629a24 100644 --- a/src/socket.io/topics.js +++ b/src/socket.io/topics.js @@ -83,6 +83,7 @@ SocketTopics.isFollowed = async function (socket, tid) { }; SocketTopics.search = async function (socket, data) { + sockets.warnDeprecated(socket, 'GET /api/search'); if (!data) { throw new Error('[[error:invalid-data]]'); } From ed0adf2ccf49988b8878d51c7d6da3512ca565d2 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 26 Oct 2021 04:59:29 +0000 Subject: [PATCH 285/412] fix(deps): update dependency nodebb-theme-persona to v11.2.18 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 1f4bd54b9e..9e7449095b 100644 --- a/install/package.json +++ b/install/package.json @@ -93,7 +93,7 @@ "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.1.5", "nodebb-theme-lavender": "5.2.1", - "nodebb-theme-persona": "11.2.17", + "nodebb-theme-persona": "11.2.18", "nodebb-theme-slick": "1.4.14", "nodebb-theme-vanilla": "12.1.5", "nodebb-widget-essentials": "5.0.4", From 3e94def68748b7ccd8f725d0cf3afc69728ef720 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Tue, 26 Oct 2021 09:09:53 +0000 Subject: [PATCH 286/412] Latest translations and fallbacks --- public/language/bg/admin/dashboard.json | 10 +++++----- public/language/bg/admin/menu.json | 2 +- public/language/it/admin/advanced/events.json | 2 +- public/language/it/admin/manage/digest.json | 2 +- public/language/it/admin/manage/users.json | 2 +- public/language/it/admin/settings/user.json | 2 +- public/language/it/error.json | 4 ++-- public/language/it/top.json | 4 ++-- public/language/it/topic.json | 6 +++--- public/language/it/user.json | 2 +- 10 files changed, 18 insertions(+), 18 deletions(-) diff --git a/public/language/bg/admin/dashboard.json b/public/language/bg/admin/dashboard.json index 4d5e2ea156..7a9cc4416c 100644 --- a/public/language/bg/admin/dashboard.json +++ b/public/language/bg/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Общо", "active-users.connections": "Връзки", - "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest-registered-users": "Гости към регистрирани потребители", + "guest": "Гост", "registered": "Регистрирани", "user-presence": "Присъствие на потребителите ", @@ -68,7 +68,7 @@ "unread": "Непрочетени", "high-presence-topics": "Теми с най-голяма присъственост", - "popular-searches": "Popular Searches", + "popular-searches": "Популярни търсения", "graphs.page-views": "Преглеждания на страниците", "graphs.page-views-registered": "Преглеждания на страниците от регистрирани потребители", @@ -76,14 +76,14 @@ "graphs.page-views-bot": "Преглеждания на страниците от ботове", "graphs.unique-visitors": "Уникални посетители", "graphs.registered-users": "Регистрирани потребители", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "Гости", "last-restarted-by": "Последно рестартиране от", "no-users-browsing": "Няма разглеждащи потребители", "back-to-dashboard": "Назад към таблото", "details.no-users": "В избрания период не са се регистрирали нови потребители", "details.no-topics": "В избрания период не са публикувани нови теми", - "details.no-searches": "No searches have been made yet", + "details.no-searches": "Все още не са правени търсения", "details.no-logins": "В избрания период не са отчетени вписвания", "details.logins-static": "NodeBB запазва данни за сесията в продължение на %1 дни, така че в следната таблица могат да се видят само последните активни сесии", "details.logins-login-time": "Време на вписване" diff --git a/public/language/bg/admin/menu.json b/public/language/bg/admin/menu.json index 52ac9da1ba..6b2b2fc2c7 100644 --- a/public/language/bg/admin/menu.json +++ b/public/language/bg/admin/menu.json @@ -4,7 +4,7 @@ "dashboard/logins": "Вписвания", "dashboard/users": "Потребители", "dashboard/topics": "Теми", - "dashboard/searches": "Searches", + "dashboard/searches": "Търсения", "section-general": "Общи", "section-manage": "Управление", diff --git a/public/language/it/admin/advanced/events.json b/public/language/it/admin/advanced/events.json index 23c3050407..6f202cbdb1 100644 --- a/public/language/it/admin/advanced/events.json +++ b/public/language/it/admin/advanced/events.json @@ -3,7 +3,7 @@ "no-events": "Non ci sono eventi", "control-panel": "Pannello di controllo eventi", "delete-events": "Elimina eventi", - "confirm-delete-all-events": "Are you sure you want to delete all logged events?", + "confirm-delete-all-events": "Sei sicuro di voler eliminare tutti gli eventi registrati?", "filters": "Filtri", "filters-apply": "Applica filtri", "filter-type": "Tipo evento", diff --git a/public/language/it/admin/manage/digest.json b/public/language/it/admin/manage/digest.json index 6747ea6c86..9e66d7500c 100644 --- a/public/language/it/admin/manage/digest.json +++ b/public/language/it/admin/manage/digest.json @@ -13,7 +13,7 @@ "resent-single": "Invio del riepilogo manuale completato", "resent-day": "Rinvio riepilogo giornaliero", "resent-week": "Rinvio del riepilogo settimanale", - "resent-biweek": "Bi-Weekly digest resent", + "resent-biweek": "Re invio riepilogo bisettimanale", "resent-month": "Rinvio del riepilogo mensile", "null": "Mai", "manual-run": "Esecuzione riepilogo manuale:", diff --git a/public/language/it/admin/manage/users.json b/public/language/it/admin/manage/users.json index d1310df1c7..ad076e6a89 100644 --- a/public/language/it/admin/manage/users.json +++ b/public/language/it/admin/manage/users.json @@ -47,7 +47,7 @@ "users.uid": "id utente", "users.username": "username", "users.email": "email", - "users.no-email": "(no email)", + "users.no-email": "(nessuna email)", "users.ip": "IP", "users.postcount": "numero di post", "users.reputation": "reputazione", diff --git a/public/language/it/admin/settings/user.json b/public/language/it/admin/settings/user.json index f1edcb6e9d..13f3f5f9ea 100644 --- a/public/language/it/admin/settings/user.json +++ b/public/language/it/admin/settings/user.json @@ -71,7 +71,7 @@ "digest-freq.off": "Spento", "digest-freq.daily": "Quotidiano", "digest-freq.weekly": "Settimanale", - "digest-freq.biweekly": "Bi-Weekly", + "digest-freq.biweekly": "Bisettimanale", "digest-freq.monthly": "Mensile", "email-chat-notifs": "Manda una email se arriva un nuovo messaggio di chat e non sono online", "email-post-notif": "Manda una email quando ci sono nuove risposte a discussioni a cui sono iscritto", diff --git a/public/language/it/error.json b/public/language/it/error.json index a0c3a177de..53c0ebf39c 100644 --- a/public/language/it/error.json +++ b/public/language/it/error.json @@ -36,7 +36,7 @@ "email-not-confirmed-chat": "Non puoi chattare finché non confermi la tua email, per favore clicca qui per confermare la tua email.", "email-not-confirmed-email-sent": "La tua email non è stata ancora confermata, controlla la tua casella di posta per l'email di conferma. Non potrai pubblicare post o chattare fino a quando la tua email non sarà confermata.", "no-email-to-confirm": "Il tuo account non ha un'email impostata. Un'email è necessaria per il recupero dell'account. Clicca qui per inserire un'email.", - "user-doesnt-have-email": "User \"%1\" does not have an email set.", + "user-doesnt-have-email": "L'utente \"%1\" non ha impostato un email.", "email-confirm-failed": "Non abbiamo potuto confermare la tua email, per favore riprovaci più tardi.", "confirm-email-already-sent": "Email di conferma già inviata, per favore attendere %1 minuto(i) per inviarne un'altra.", "sendmail-not-found": "Impossibile trovare l'eseguibile di sendmail, per favore assicurati che sia installato ed eseguibile dall'utente che esegue NodeBB.", @@ -104,7 +104,7 @@ "already-bookmarked": "Hai già aggiunto questa discussione ai preferiti.", "already-unbookmarked": "Hai già rimosso questa discussione dai preferiti", "cant-ban-other-admins": "Non puoi bannare altri amministratori!", - "cant-make-banned-users-admin": "You can't make banned users admin.", + "cant-make-banned-users-admin": "Non puoi rendere amministratori gli utenti bannati.", "cant-remove-last-admin": "Sei l'unico Amministratore. Aggiungi un altro amministratore prima di rimuovere il tuo ruolo", "account-deletion-disabled": "L'eliminazione dell'account è disabilitata", "cant-delete-admin": "Togli i privilegi amministrativi da questo account prima di provare ad eliminarlo.", diff --git a/public/language/it/top.json b/public/language/it/top.json index b8a05bfa5f..5146312ddf 100644 --- a/public/language/it/top.json +++ b/public/language/it/top.json @@ -1,4 +1,4 @@ { - "title": "Top", - "no_top_topics": "No top topics" + "title": "In alto", + "no_top_topics": "Nessuna discussione principale" } \ No newline at end of file diff --git a/public/language/it/topic.json b/public/language/it/topic.json index 025fd42f30..47a4170cf6 100644 --- a/public/language/it/topic.json +++ b/public/language/it/topic.json @@ -47,7 +47,7 @@ "restored-by": "Ripristinato da", "moved-from-by": "Spostato da %1 da", "queued-by": "Post in coda per l'approvazione →", - "backlink": "Referenced by", + "backlink": "Referenziato da", "bookmark_instructions": "Clicca qui per tornare all'ultimo post letto in questa discussione.", "flag-post": "Segnala questo post", "flag-user": "Segnala questo utente", @@ -139,7 +139,7 @@ "composer.handle_placeholder": "Inserisci qui il tuo nome/nome utente ospite", "composer.discard": "Annulla", "composer.submit": "Invia", - "composer.additional-options": "Additional Options", + "composer.additional-options": "Opzioni aggiuntive", "composer.schedule": "Pianifica", "composer.replying_to": "Rispondendo a %1", "composer.new_topic": "Nuova Discussione", @@ -160,7 +160,7 @@ "newest_to_oldest": "Da Nuovi a Vecchi", "most_votes": "Più Voti", "most_posts": "Più Post", - "most_views": "Most Views", + "most_views": "Più visualizzazioni", "stale.title": "Preferisci creare una nuova discussione?", "stale.warning": "Il topic al quale stai rispondendo è abbastanza vecchio. Vorresti piuttosto creare un nuovo topic in riferimento a questo nella tua risposta?", "stale.create": "Crea una nuova discussione", diff --git a/public/language/it/user.json b/public/language/it/user.json index 1faa0b03fa..38592bc8bb 100644 --- a/public/language/it/user.json +++ b/public/language/it/user.json @@ -94,7 +94,7 @@ "digest_off": "Spento", "digest_daily": "Quotidiano", "digest_weekly": "Settimanale", - "digest_biweekly": "Bi-Weekly", + "digest_biweekly": "Bisettimanale", "digest_monthly": "Mensile", "has_no_follower": "Questo utente non è seguito da nessuno :(", "follows_no_one": "Questo utente non segue nessuno :(", From 49b8b983b642652a0f9638a7bd142a48f6d06c5d Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 26 Oct 2021 09:13:31 +0000 Subject: [PATCH 287/412] fix(deps): update dependency nodebb-theme-vanilla to v12.1.6 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 9e7449095b..0fcd439d8a 100644 --- a/install/package.json +++ b/install/package.json @@ -95,7 +95,7 @@ "nodebb-theme-lavender": "5.2.1", "nodebb-theme-persona": "11.2.18", "nodebb-theme-slick": "1.4.14", - "nodebb-theme-vanilla": "12.1.5", + "nodebb-theme-vanilla": "12.1.6", "nodebb-widget-essentials": "5.0.4", "nodemailer": "^6.5.0", "nprogress": "0.2.0", From 0728a99453283a37b85e08be9ab287acbd310878 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 26 Oct 2021 12:05:55 +0000 Subject: [PATCH 288/412] chore(deps): update dependency lint-staged to v11.2.5 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 0fcd439d8a..970e165d84 100644 --- a/install/package.json +++ b/install/package.json @@ -152,7 +152,7 @@ "grunt-contrib-watch": "1.1.0", "husky": "7.0.4", "jsdom": "18.0.0", - "lint-staged": "11.2.4", + "lint-staged": "11.2.5", "mocha": "9.1.3", "mocha-lcov-reporter": "1.3.0", "mockdate": "3.0.5", From 5a328485ddb5c863531435078c8958a1a7ff1a08 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Tue, 26 Oct 2021 14:22:36 -0400 Subject: [PATCH 289/412] Revert "fix: only show email confirmation warning toast on pages that it applies" This reverts commit 1bd1cc74a41106746add384ac61d38016f4219e4. --- public/src/app.js | 20 ++------------------ public/src/client/category.js | 2 -- public/src/client/recent.js | 1 - public/src/client/topic.js | 1 - 4 files changed, 2 insertions(+), 22 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index 14e45d2794..d909fd9f15 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -97,6 +97,7 @@ app.cacheBuster = null; }); createHeaderTooltips(); + app.showEmailConfirmWarning(); app.showCookieWarning(); registerServiceWorker(); @@ -754,24 +755,7 @@ app.cacheBuster = null; app.showEmailConfirmWarning = async (err) => { const storage = await app.require('storage'); - let showModal = false; - switch (ajaxify.data.template.name) { - case 'recent': { - showModal = !ajaxify.data.canPost; - break; - } - - case 'category': { - showModal = !ajaxify.data.privileges['topics:create']; - break; - } - - case 'topic': { - showModal = !ajaxify.data.privileges['topics:reply']; - } - } - - if (!showModal || !app.user.uid || parseInt(storage.getItem('email-confirm-dismiss'), 10) === 1) { + if (!app.user.uid || parseInt(storage.getItem('email-confirm-dismiss'), 10) === 1) { return; } const msg = { diff --git a/public/src/client/category.js b/public/src/client/category.js index 92cb42e061..03d63bae86 100644 --- a/public/src/client/category.js +++ b/public/src/client/category.js @@ -48,8 +48,6 @@ define('forum/category', [ }, }); - app.showEmailConfirmWarning(); - hooks.fire('action:topics.loaded', { topics: ajaxify.data.topics }); hooks.fire('action:category.loaded', { cid: ajaxify.data.cid }); }; diff --git a/public/src/client/recent.js b/public/src/client/recent.js index e54415d814..9d0a9904a2 100644 --- a/public/src/client/recent.js +++ b/public/src/client/recent.js @@ -7,7 +7,6 @@ define('forum/recent', ['topicList'], function (topicList) { app.enterRoom('recent_topics'); topicList.init('recent'); - app.showEmailConfirmWarning(); }; return Recent; diff --git a/public/src/client/topic.js b/public/src/client/topic.js index bc0a340be3..5cc2da69a5 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -74,7 +74,6 @@ define('forum/topic', [ $(window).on('scroll', updateTopicTitle); handleTopicSearch(); - app.showEmailConfirmWarning(); hooks.fire('action:topic.loaded', ajaxify.data); }; From 80ea12c1c1963f5b39fb64841e4f3c8da3c87af2 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Tue, 26 Oct 2021 14:28:37 -0400 Subject: [PATCH 290/412] feat: new ACP option `emailPrompt` ... which allows administrators to disable the client-side prompt to encourage users to enter or confirm their email addresses --- install/data/defaults.json | 1 + public/language/en-GB/admin/settings/email.json | 4 +++- public/language/en-GB/error.json | 4 ++-- public/src/app.js | 2 +- src/controllers/api.js | 1 + src/views/admin/settings/email.tpl | 8 ++++++++ 6 files changed, 16 insertions(+), 4 deletions(-) diff --git a/install/data/defaults.json b/install/data/defaults.json index dfe0c2b7bc..3b92872280 100644 --- a/install/data/defaults.json +++ b/install/data/defaults.json @@ -138,6 +138,7 @@ "emailConfirmInterval": 10, "removeEmailNotificationImages": 0, "includeUnverifiedEmails": 0, + "emailPrompt": 1, "inviteExpiration": 7, "dailyDigestFreq": "off", "digestHour": 17, diff --git a/public/language/en-GB/admin/settings/email.json b/public/language/en-GB/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/en-GB/admin/settings/email.json +++ b/public/language/en-GB/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/en-GB/error.json b/public/language/en-GB/error.json index 77ef15c699..0b5e714e26 100644 --- a/public/language/en-GB/error.json +++ b/public/language/en-GB/error.json @@ -39,8 +39,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/src/app.js b/public/src/app.js index d909fd9f15..63787b6fe3 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -755,7 +755,7 @@ app.cacheBuster = null; app.showEmailConfirmWarning = async (err) => { const storage = await app.require('storage'); - if (!app.user.uid || parseInt(storage.getItem('email-confirm-dismiss'), 10) === 1) { + if (!config.emailPrompt || !app.user.uid || parseInt(storage.getItem('email-confirm-dismiss'), 10) === 1) { return; } const msg = { diff --git a/src/controllers/api.js b/src/controllers/api.js index 3e4e2fa216..984ea98e42 100644 --- a/src/controllers/api.js +++ b/src/controllers/api.js @@ -80,6 +80,7 @@ apiController.loadConfig = async function (req) { size: meta.config.topicThumbSize, }, iconBackgrounds: await user.getIconBackgrounds(req.uid), + emailPrompt: meta.config.emailPrompt, }; let settings = config; diff --git a/src/views/admin/settings/email.tpl b/src/views/admin/settings/email.tpl index e358692127..7f90431b96 100644 --- a/src/views/admin/settings/email.tpl +++ b/src/views/admin/settings/email.tpl @@ -42,6 +42,14 @@

    [[admin/settings/email:include-unverified-warning]]

    + +
    + +
    +

    [[admin/settings/email:prompt-help]]

    From 9b68dc37cccaf7cdfcb3af2f164962cb7d1e6547 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Tue, 26 Oct 2021 18:30:00 +0000 Subject: [PATCH 291/412] chore(i18n): fallback strings for new resources: nodebb.admin-settings-email, nodebb.error --- public/language/ar/admin/settings/email.json | 4 +++- public/language/ar/error.json | 4 ++-- public/language/bg/admin/settings/email.json | 4 +++- public/language/bg/error.json | 4 ++-- public/language/bn/admin/settings/email.json | 4 +++- public/language/bn/error.json | 4 ++-- public/language/cs/admin/settings/email.json | 4 +++- public/language/cs/error.json | 4 ++-- public/language/da/admin/settings/email.json | 4 +++- public/language/da/error.json | 4 ++-- public/language/de/admin/settings/email.json | 4 +++- public/language/de/error.json | 4 ++-- public/language/el/admin/settings/email.json | 4 +++- public/language/el/error.json | 4 ++-- public/language/en-US/admin/settings/email.json | 4 +++- public/language/en-US/error.json | 4 ++-- public/language/en-x-pirate/admin/settings/email.json | 4 +++- public/language/en-x-pirate/error.json | 4 ++-- public/language/es/admin/settings/email.json | 4 +++- public/language/es/error.json | 4 ++-- public/language/et/admin/settings/email.json | 4 +++- public/language/et/error.json | 4 ++-- public/language/fa-IR/admin/settings/email.json | 4 +++- public/language/fa-IR/error.json | 4 ++-- public/language/fi/admin/settings/email.json | 4 +++- public/language/fi/error.json | 4 ++-- public/language/fr/admin/settings/email.json | 4 +++- public/language/fr/error.json | 4 ++-- public/language/gl/admin/settings/email.json | 4 +++- public/language/gl/error.json | 4 ++-- public/language/he/admin/settings/email.json | 4 +++- public/language/he/error.json | 4 ++-- public/language/hr/admin/settings/email.json | 4 +++- public/language/hr/error.json | 4 ++-- public/language/hu/admin/settings/email.json | 4 +++- public/language/hu/error.json | 4 ++-- public/language/id/admin/settings/email.json | 4 +++- public/language/id/error.json | 4 ++-- public/language/it/admin/settings/email.json | 6 ++++-- public/language/it/error.json | 4 ++-- public/language/ja/admin/settings/email.json | 4 +++- public/language/ja/error.json | 4 ++-- public/language/ko/admin/settings/email.json | 4 +++- public/language/ko/error.json | 4 ++-- public/language/lt/admin/settings/email.json | 4 +++- public/language/lt/error.json | 4 ++-- public/language/lv/admin/settings/email.json | 4 +++- public/language/lv/error.json | 4 ++-- public/language/ms/admin/settings/email.json | 4 +++- public/language/ms/error.json | 4 ++-- public/language/nb/admin/settings/email.json | 4 +++- public/language/nb/error.json | 4 ++-- public/language/nl/admin/settings/email.json | 4 +++- public/language/nl/error.json | 4 ++-- public/language/pl/admin/settings/email.json | 4 +++- public/language/pl/error.json | 4 ++-- public/language/pt-BR/admin/settings/email.json | 4 +++- public/language/pt-BR/error.json | 4 ++-- public/language/pt-PT/admin/settings/email.json | 4 +++- public/language/pt-PT/error.json | 4 ++-- public/language/ro/admin/settings/email.json | 4 +++- public/language/ro/error.json | 4 ++-- public/language/ru/admin/settings/email.json | 4 +++- public/language/ru/error.json | 4 ++-- public/language/rw/admin/settings/email.json | 4 +++- public/language/rw/error.json | 4 ++-- public/language/sc/admin/settings/email.json | 4 +++- public/language/sc/error.json | 4 ++-- public/language/sk/admin/settings/email.json | 4 +++- public/language/sk/error.json | 4 ++-- public/language/sl/admin/settings/email.json | 4 +++- public/language/sl/error.json | 4 ++-- public/language/sr/admin/settings/email.json | 4 +++- public/language/sr/error.json | 4 ++-- public/language/sv/admin/settings/email.json | 4 +++- public/language/sv/error.json | 4 ++-- public/language/th/admin/settings/email.json | 4 +++- public/language/th/error.json | 4 ++-- public/language/tr/admin/settings/email.json | 4 +++- public/language/tr/error.json | 4 ++-- public/language/uk/admin/settings/email.json | 4 +++- public/language/uk/error.json | 4 ++-- public/language/vi/admin/settings/email.json | 4 +++- public/language/vi/error.json | 4 ++-- public/language/zh-CN/admin/settings/email.json | 4 +++- public/language/zh-CN/error.json | 4 ++-- public/language/zh-TW/admin/settings/email.json | 4 +++- public/language/zh-TW/error.json | 4 ++-- 88 files changed, 221 insertions(+), 133 deletions(-) diff --git a/public/language/ar/admin/settings/email.json b/public/language/ar/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/ar/admin/settings/email.json +++ b/public/language/ar/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/ar/error.json b/public/language/ar/error.json index a665488fc0..0dc18f5b59 100644 --- a/public/language/ar/error.json +++ b/public/language/ar/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "لا يمكنك الدردشة حتى تقوم بتأكيد بريدك الإلكتروني، الرجاء إضغط هنا لتأكيد بريدك اﻹلكتروني.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "لم نستطع تفعيل بريدك الإلكتروني، المرجو المحاولة لاحقًا.", "confirm-email-already-sent": "لقد تم ارسال بريد التأكيد، الرجاء اﻹنتظار 1% دقائق لإعادة اﻹرسال", diff --git a/public/language/bg/admin/settings/email.json b/public/language/bg/admin/settings/email.json index 907ca96637..8bd62c410a 100644 --- a/public/language/bg/admin/settings/email.json +++ b/public/language/bg/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Новите потребители задължително трябва да предоставят е-поща", "require-email-address-warning": "По подразбиране потребителите могат да не въвеждат адрес на е-поща. Ако включите това, те задължително ще трябва да предоставят е-поща, за да могат да се регистрират. Това не означава, че потребителят ще въведе съществуваща е-поща, нито че тя ще е негова.", "include-unverified-emails": "Изпращане на е-писма към получатели, които не са потвърдили изрично е-пощата си", - "include-unverified-warning": "За потребителите, които имат свързана е-поща с регистрацията си, тя се смята за потвърдена. Но има ситуации, в които това не е така (например при ползване на регистрация от друга система, но и в други случаи), Включете тази настройка на собствен риск – изпращането на е-писма към непотвърдени адреси може да нарушава определени местни закони против нежеланата поща." + "include-unverified-warning": "За потребителите, които имат свързана е-поща с регистрацията си, тя се смята за потвърдена. Но има ситуации, в които това не е така (например при ползване на регистрация от друга система, но и в други случаи), Включете тази настройка на собствен риск – изпращането на е-писма към непотвърдени адреси може да нарушава определени местни закони против нежеланата поща.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/bg/error.json b/public/language/bg/error.json index bd812e7802..104b4a3d92 100644 --- a/public/language/bg/error.json +++ b/public/language/bg/error.json @@ -34,8 +34,8 @@ "email-invited": "На тази е-поща вече е била изпратена покана", "email-not-confirmed": "Публикуването в някои категории и теми ще бъде възможно едва след като е-пощата Ви бъде потвърдена. Щръкнете тук, за да Ви изпратим е-писмо за потвърждение.", "email-not-confirmed-chat": "Няма да можете да пишете в разговори, докато е-пощата Ви не бъде потвърдена. Моля, натиснете тук, за да потвърдите е-пощата си.", - "email-not-confirmed-email-sent": "Вашата е-поща все още не е потвърдена. Моля, проверете входящата си кутия за писмото за потвърждение. Няма да можете да публикувате съобщения или да пишете в разговори, докато е-пощата Ви не бъде потвърдена.", - "no-email-to-confirm": "Нямате зададена е-поща. Тя е необходима за възстановяването на акаунта в случай на проблем. Натиснете тук, за да въведете е-поща.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "Потребителят „%1“ няма зададена е-поща.", "email-confirm-failed": "Не успяхме да потвърдим е-пощата Ви. Моля, опитайте отново по-късно.", "confirm-email-already-sent": "Е-писмото за потвърждение вече е изпратено. Моля, почакайте още %1 минута/и, преди да изпратите ново.", diff --git a/public/language/bn/admin/settings/email.json b/public/language/bn/admin/settings/email.json index d6dc447108..7970d5ec70 100644 --- a/public/language/bn/admin/settings/email.json +++ b/public/language/bn/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/bn/error.json b/public/language/bn/error.json index 2ef1609ea2..8bc3ee96e4 100644 --- a/public/language/bn/error.json +++ b/public/language/bn/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/cs/admin/settings/email.json b/public/language/cs/admin/settings/email.json index 767bff6b23..daf0596406 100644 --- a/public/language/cs/admin/settings/email.json +++ b/public/language/cs/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/cs/error.json b/public/language/cs/error.json index 1fba3a9e8a..4f156be9bc 100644 --- a/public/language/cs/error.json +++ b/public/language/cs/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Nebude schopen konverzovat, dokud nebude váš e-mail potvrzen. Pro jeho potvrzení klikněte zde.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Nemohli jsme ověřit vaši e-mailovou adresu, zkuste to později.", "confirm-email-already-sent": "Potvrzovací e-mail byl již odeslán. Vyčkejte %1 minut/y, chcete-li odeslat další.", diff --git a/public/language/da/admin/settings/email.json b/public/language/da/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/da/admin/settings/email.json +++ b/public/language/da/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/da/error.json b/public/language/da/error.json index e37b7a59c6..6ee0328692 100644 --- a/public/language/da/error.json +++ b/public/language/da/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Du kan ikke chatte før din email er bekræftet, klik her for at bekræfte din email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Vi kunne ikke bekræfte din email, prøv igen senere.", "confirm-email-already-sent": "Bekræftelses email er allerede afsendt, vent venligt %1 minut(ter) for at sende endnu en.", diff --git a/public/language/de/admin/settings/email.json b/public/language/de/admin/settings/email.json index 72dcba0ec5..9de1ce0df1 100644 --- a/public/language/de/admin/settings/email.json +++ b/public/language/de/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/de/error.json b/public/language/de/error.json index 96e9ff7b4f..08c4e7732c 100644 --- a/public/language/de/error.json +++ b/public/language/de/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Du kannst den Chat erst nutzen wenn deine E-Mail bestätigt wurde, bitte klicke hier, um deine E-Mail zu bestätigen.", - "email-not-confirmed-email-sent": "Deine Email-Adresse wurde noch nicht bestätigt, bitte kontrolliere dein Postfach nach einer Bestätigungsmail. Du kannst keine Beiträge erstellen oder chatten bis deine Email-Adresse bestätigt wurde.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Wir konnten deine E-Mail-Adresse nicht bestätigen, bitte versuch es später noch einmal", "confirm-email-already-sent": "Die Bestätigungsmail wurde verschickt. Bitte warte %1 Minute(n), um eine weitere zu verschicken.", diff --git a/public/language/el/admin/settings/email.json b/public/language/el/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/el/admin/settings/email.json +++ b/public/language/el/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/el/error.json b/public/language/el/error.json index c3e7b62e21..827c635748 100644 --- a/public/language/el/error.json +++ b/public/language/el/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/en-US/admin/settings/email.json b/public/language/en-US/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/en-US/admin/settings/email.json +++ b/public/language/en-US/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/en-US/error.json b/public/language/en-US/error.json index 55f49fe028..6eb0983661 100644 --- a/public/language/en-US/error.json +++ b/public/language/en-US/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/en-x-pirate/admin/settings/email.json b/public/language/en-x-pirate/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/en-x-pirate/admin/settings/email.json +++ b/public/language/en-x-pirate/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/en-x-pirate/error.json b/public/language/en-x-pirate/error.json index 55f49fe028..6eb0983661 100644 --- a/public/language/en-x-pirate/error.json +++ b/public/language/en-x-pirate/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/es/admin/settings/email.json b/public/language/es/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/es/admin/settings/email.json +++ b/public/language/es/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/es/error.json b/public/language/es/error.json index dea34e793c..52f3fb57af 100644 --- a/public/language/es/error.json +++ b/public/language/es/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "No puedes usar el chat hasta que confirmes tu dirección de correo electrónico, por favor haz click aquí para confirmar tu correo.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "No se ha podido confirmar su email, por favor inténtelo de nuevo más tarde.", "confirm-email-already-sent": "El email de confirmación ya ha sido enviado, por favor espera %1 minuto(s) para enviar otro.", diff --git a/public/language/et/admin/settings/email.json b/public/language/et/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/et/admin/settings/email.json +++ b/public/language/et/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/et/error.json b/public/language/et/error.json index 2093bbfc20..ddb750b45f 100644 --- a/public/language/et/error.json +++ b/public/language/et/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Sõnumeid ei ole võimalik enne saata kui sinu email on kinnitatud. Kinnitamiseks vajuta siia.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Meil ei õnnestunud sinu emaili kinnitada, proovi hiljem uuesti.", "confirm-email-already-sent": "Kinnituskiri on juba saadetud, palun oota %1 minut(it) uue kirja saatmiseks.", diff --git a/public/language/fa-IR/admin/settings/email.json b/public/language/fa-IR/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/fa-IR/admin/settings/email.json +++ b/public/language/fa-IR/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/fa-IR/error.json b/public/language/fa-IR/error.json index 769fec100a..b707c9d3d9 100644 --- a/public/language/fa-IR/error.json +++ b/public/language/fa-IR/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "شما تا قبل از تایید ایمیل قادر به چت نیستید، لطفا برای تایید ایمیل خود اینجا کلیک کنید", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "سیستم موفق به تایید ایمیل شما نشد، لطفا بعدا دوباره سعی کنید", "confirm-email-already-sent": "ایمیل فعال‌سازی قبلا فرستاده شده، لطفا %1 دقیقه صبر کنید تا ایمیل دیگری فرستاده شود.", diff --git a/public/language/fi/admin/settings/email.json b/public/language/fi/admin/settings/email.json index 468ca7d464..2dd033e1ad 100644 --- a/public/language/fi/admin/settings/email.json +++ b/public/language/fi/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/fi/error.json b/public/language/fi/error.json index baa398e678..d379bc1081 100644 --- a/public/language/fi/error.json +++ b/public/language/fi/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Et voi keskustella ennen kuin sähköpostiosoitteesi on vahvistettu, ole hyvä ja paina tästä vahvistaaksesi sen.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/fr/admin/settings/email.json b/public/language/fr/admin/settings/email.json index 9e10649b83..1f5b030ed3 100644 --- a/public/language/fr/admin/settings/email.json +++ b/public/language/fr/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Exiger une adresse e-mail aux nouveaux utilisateurs ", "require-email-address-warning": "Par défaut, les utilisateurs peuvent refuser de saisir une adresse e-mail. L'activation de cette option oblige de renseigner une une adresse e-mail lors de l'inscription. Ne garantit pas que l'utilisateur entrera adresse e-mail valide, ni même une adresse qu'il possède.", "include-unverified-emails": "Envoyer des mails aux destinataires qui n'ont pas explicitement confirmé leurs mails", - "include-unverified-warning": "Par défaut, les utilisateurs dont les mails sont associés à leur compte ont déjà été vérifiés, mais il existe des situations où ce n'est pas le cas (par exemple, les connexions SSO, les utilisateurs bénéficiant de droits acquis, etc.). Activez ce paramètre à vos risques et périls – l'envoi de mails à des adresses non vérifiées peut constituer une violation des lois anti-spam régionales." + "include-unverified-warning": "Par défaut, les utilisateurs dont les mails sont associés à leur compte ont déjà été vérifiés, mais il existe des situations où ce n'est pas le cas (par exemple, les connexions SSO, les utilisateurs bénéficiant de droits acquis, etc.). Activez ce paramètre à vos risques et périls – l'envoi de mails à des adresses non vérifiées peut constituer une violation des lois anti-spam régionales.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/fr/error.json b/public/language/fr/error.json index 6f53fa2605..0da22c466c 100644 --- a/public/language/fr/error.json +++ b/public/language/fr/error.json @@ -34,8 +34,8 @@ "email-invited": "Cet utilisateur a déjà été invité.", "email-not-confirmed": "La publication dans certaines catégories ou sujets sera activée après confirmation de e-mail, veuillez cliquer ici pour envoyer un e-mail de confirmation.", "email-not-confirmed-chat": "Il ne vous est pas possible d'utiliser le chat tant que votre adresse email n'a pas été vérifiée. Veuillez cliquer ici pour confirmer votre adresse email.", - "email-not-confirmed-email-sent": "Votre email n'a pas encore été confirmé, veuillez vérifier votre boîte mail. Vous ne pourrez pas poster ou discuter avant que votre email ne soit confirmé.", - "no-email-to-confirm": "Votre compte n'a pas d'adresse mail définie. Un mail est nécessaire pour la récupération du compte. Veuillez cliquer ici pour entrer un courriel.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "L'utilisateur « %1 » n'a pas d'adresse e-mail.", "email-confirm-failed": "Votre adresse email n'a pas pu être vérifiée. Veuillez ré-essayer plus tard.", "confirm-email-already-sent": "L'email de confirmation a déjà été envoyé. Veuillez attendre %1 minute(s) avant de redemander un nouvel envoi.", diff --git a/public/language/gl/admin/settings/email.json b/public/language/gl/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/gl/admin/settings/email.json +++ b/public/language/gl/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/gl/error.json b/public/language/gl/error.json index 441b6c3f00..2d6e135643 100644 --- a/public/language/gl/error.json +++ b/public/language/gl/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Non podes charlar ata que confirmes o teu correo, por favor pica aquí para confirmalo.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Non podemos confirmar o teu enderezo, por favor téntao de novo máis tarde.", "confirm-email-already-sent": "O correo de confirmación foi enviado, agarda %1 minute(s) para enviar outro.", diff --git a/public/language/he/admin/settings/email.json b/public/language/he/admin/settings/email.json index 75ad0826e2..0c98d497e4 100644 --- a/public/language/he/admin/settings/email.json +++ b/public/language/he/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/he/error.json b/public/language/he/error.json index 41575db79d..cdfa227e31 100644 --- a/public/language/he/error.json +++ b/public/language/he/error.json @@ -34,8 +34,8 @@ "email-invited": "כבר נשלחה הזמנה לדוא\"ל זה", "email-not-confirmed": "פרסום בקטגוריות או בנושאים מסוימים מופעל רק לאחר אישור הדוא\"ל שלך, אנא לחץ כאן כדי לשלוח אימות לדוא\"ל שלך.", "email-not-confirmed-chat": "אין באפשרותך לשוחח עד שהדוא\"ל שלך יאושר, אנא לחץ כאן כדי לאשר את הדוא\"ל שלך.", - "email-not-confirmed-email-sent": "הדוא\"ל שלך עדין לא אושר. אנא בדוק בתיבת הדואר בנוגע לאישור הדוא\"ל שנשלח לך על ידינו. לא תוכל לכתוב פוסטים ולהשתמש בצ'אט לפני אימות הדוא\"ל שלך.", - "no-email-to-confirm": "בחשבונך לא הוגדר דוא\"ל. כתובת דוא\"ל נחוץ לשחזור חשבון. אנא לחץ כאן כדי להכניס דוא\"ל.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "למשתמש \"%1\" לא הוגדר כתובת דוא\"ל.", "email-confirm-failed": "לא הצלחנו לאשר את הדוא\"ל שלך, תנסה שוב אחר כך", "confirm-email-already-sent": "דוא\"ל האישור כבר נשלח, אנא המתן %1 דקות כדי לשלוח דוא\"ל נוסף.", diff --git a/public/language/hr/admin/settings/email.json b/public/language/hr/admin/settings/email.json index 9ad1e8a6e0..48d010cef5 100644 --- a/public/language/hr/admin/settings/email.json +++ b/public/language/hr/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/hr/error.json b/public/language/hr/error.json index d6005b45f4..df2dd79ccc 100644 --- a/public/language/hr/error.json +++ b/public/language/hr/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Ne možete razgovarati dok Vaš email nije potvrđen. Kliknite ovdje da biste potvrdili svoj email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Nismo u mogućnosti potvrditi Vaš email, pokušajte ponovno kasnije.", "confirm-email-already-sent": "Potvrdni email je poslan, počekajte %1 minuta za ponovni pokušaj.", diff --git a/public/language/hu/admin/settings/email.json b/public/language/hu/admin/settings/email.json index b0ee8a1907..5206a293fb 100644 --- a/public/language/hu/admin/settings/email.json +++ b/public/language/hu/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/hu/error.json b/public/language/hu/error.json index 7ecd919b5d..5e6a9e604d 100644 --- a/public/language/hu/error.json +++ b/public/language/hu/error.json @@ -34,8 +34,8 @@ "email-invited": "Ez az email cím már meg lett hívva", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Nem küldhetsz üzenetet amíg nem erősíted meg az email címed, kattints ide az email cím megerősítéséhez!", - "email-not-confirmed-email-sent": "Az email címed még nem lett megerősítve, kérlek ellenőrizd az email fiókodba érkező leveleket. Amíg nincs az email címed megerősítve addig nem tudsz üzeneteket küldeni valamint bejegyzést közzé tenni.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Nem tudtuk ellenőrizni az e-mail címedet, kérlek próbálkozz később.", "confirm-email-already-sent": "A megerősítéshez szükséges email már el lett küldve, kérlek várj %1 percet az újraküldéshez.", diff --git a/public/language/id/admin/settings/email.json b/public/language/id/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/id/admin/settings/email.json +++ b/public/language/id/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/id/error.json b/public/language/id/error.json index 43206b24cc..b1d2322af6 100644 --- a/public/language/id/error.json +++ b/public/language/id/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/it/admin/settings/email.json b/public/language/it/admin/settings/email.json index 2368d1cb11..b203c44bfb 100644 --- a/public/language/it/admin/settings/email.json +++ b/public/language/it/admin/settings/email.json @@ -6,7 +6,7 @@ "from-help": "Il nome da visualizzare nell'email.", "smtp-transport": "Trasporto SMTP", - "smtp-transport.enabled": "Enable SMTP Transport", + "smtp-transport.enabled": "Abilita trasporto SMTP", "smtp-transport-help": "Puoi selezionare da un elenco di servizi noti o inserirne uno personalizzato.", "smtp-transport.service": "Seleziona un servizio", "smtp-transport.service-custom": "Servizio personalizzato", @@ -40,5 +40,7 @@ "require-email-address": "Richiedere ai nuovi utenti di specificare un indirizzo email", "require-email-address-warning": "Per impostazione predefinita, gli utenti possono rinunciare a inserire un indirizzo email. Abilitare questa opzione significa che devono inserire un indirizzo email per procedere con la registrazione. Non assicura che l'utente inserisca un indirizzo email reale, e nemmeno un indirizzo che possiede.", "include-unverified-emails": "Invia email a destinatari che non hanno confermato esplicitamente le loro email", - "include-unverified-warning": "Per impostazione predefinita, gli utenti con email associate al loro account sono già stati verificati, ma ci sono situazioni in cui ciò non è vero (ad esempio accessi SSO, vecchi utenti, ecc.). Abilita questa impostazione a tuo rischio e pericolo – l'invio di email a indirizzi non verificati può essere una violazione delle leggi regionali anti-spam." + "include-unverified-warning": "Per impostazione predefinita, gli utenti con email associate al loro account sono già stati verificati, ma ci sono situazioni in cui ciò non è vero (ad esempio accessi SSO, vecchi utenti, ecc.). Abilita questa impostazione a tuo rischio e pericolo – l'invio di email a indirizzi non verificati può essere una violazione delle leggi regionali anti-spam.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/it/error.json b/public/language/it/error.json index 53c0ebf39c..f05b5a3e1e 100644 --- a/public/language/it/error.json +++ b/public/language/it/error.json @@ -34,8 +34,8 @@ "email-invited": "L'email è già stata invitata", "email-not-confirmed": "Sarai abilitato a postare in alcune categorie o discussioni una volta che la tua email sarà confermata, per favore clicca qui per inviare una email di conferma.", "email-not-confirmed-chat": "Non puoi chattare finché non confermi la tua email, per favore clicca qui per confermare la tua email.", - "email-not-confirmed-email-sent": "La tua email non è stata ancora confermata, controlla la tua casella di posta per l'email di conferma. Non potrai pubblicare post o chattare fino a quando la tua email non sarà confermata.", - "no-email-to-confirm": "Il tuo account non ha un'email impostata. Un'email è necessaria per il recupero dell'account. Clicca qui per inserire un'email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "L'utente \"%1\" non ha impostato un email.", "email-confirm-failed": "Non abbiamo potuto confermare la tua email, per favore riprovaci più tardi.", "confirm-email-already-sent": "Email di conferma già inviata, per favore attendere %1 minuto(i) per inviarne un'altra.", diff --git a/public/language/ja/admin/settings/email.json b/public/language/ja/admin/settings/email.json index 33e31292fd..a3bf8a8616 100644 --- a/public/language/ja/admin/settings/email.json +++ b/public/language/ja/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/ja/error.json b/public/language/ja/error.json index 533414bbb3..bf4213818d 100644 --- a/public/language/ja/error.json +++ b/public/language/ja/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "チャットを行うにはメールアドレスの確認を行う必要があります。メールアドレスを確認するためにはここをクリックしてください。", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "メールアドレスの確認が出来ませんでした。再度お試しください。", "confirm-email-already-sent": "確認のメールは既に送信されています。再度送信するには、%1分後に再度お試しください。", diff --git a/public/language/ko/admin/settings/email.json b/public/language/ko/admin/settings/email.json index 3dfd884bc6..2b6b3587dd 100644 --- a/public/language/ko/admin/settings/email.json +++ b/public/language/ko/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "신규 사용자에게 이메일 주소 설정 요구", "require-email-address-warning": "기본적으로 사용자들은 이메일 주소 입력을 거부할 수 있습니다. 이 설정을 활성화하면 사용자 등록 시 이메일 주소를 입력해야 진행할 수 있습니다. 하지만 해당 이메일 주소가 유효한 주소인지는 확인하지 않습니다.", "include-unverified-emails": "전자 메일을 명시적으로 확인하지 않은 수신자에게 전자 메일 보내기", - "include-unverified-warning": "기본적으로 계정과 연결된 전자 메일이 있는 사용자는 이미 확인되었지만 그렇지 않은 경우가 있습니다(예: SSO 로그인, 약관으로부터 제외된 사용자 등). 사용자가 위험을 감수하고 이 설정을 사용하도록 설정합니다. – 확인되지 않은 주소로 이메일을 보내는 것은 지역별 스팸 방지법을 위반하는 것일 수 있습니다." + "include-unverified-warning": "기본적으로 계정과 연결된 전자 메일이 있는 사용자는 이미 확인되었지만 그렇지 않은 경우가 있습니다(예: SSO 로그인, 약관으로부터 제외된 사용자 등). 사용자가 위험을 감수하고 이 설정을 사용하도록 설정합니다. – 확인되지 않은 주소로 이메일을 보내는 것은 지역별 스팸 방지법을 위반하는 것일 수 있습니다.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/ko/error.json b/public/language/ko/error.json index 9eab7dcfbf..bc4af29b50 100644 --- a/public/language/ko/error.json +++ b/public/language/ko/error.json @@ -34,8 +34,8 @@ "email-invited": "해당 이메일의 사용자는 이미 초대되었습니다.", "email-not-confirmed": "이메일 인증이 완료된 후 카테고리나 화제에 새로운 포스트를 작성할 수 있습니다. 여기를 눌러 인증 메일을 다시 발송할 수 있습니다.", "email-not-confirmed-chat": "아직 이메일이 인증되지 않아 채팅 기능을 사용할 수 없습니다. 여기를 눌러 이메일 인증을 진행하세요.", - "email-not-confirmed-email-sent": "이메일 인증이 완료되지 않았습니다. 수신함에서 인증 메일을 확인해주세요. 인증이 완료되기 전까지는 글을 작성하거나 채팅 참여가 불가능합니다.", - "no-email-to-confirm": "계정에 전자 메일 설정이 없습니다. 계정 복구를 위해 이메일이 필요합니다. 이메일을 입력하려면 여기를 클릭하십시오.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "이메일 인증이 실패하였습니다. 잠시 후에 다시 시도하세요.", "confirm-email-already-sent": "인증 메일이 이미 발송되었습니다. 다시 보내려면 %1분을 기다리세요.", diff --git a/public/language/lt/admin/settings/email.json b/public/language/lt/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/lt/admin/settings/email.json +++ b/public/language/lt/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/lt/error.json b/public/language/lt/error.json index 96348d2cbe..aa1e74f66a 100644 --- a/public/language/lt/error.json +++ b/public/language/lt/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Jūs negalite bendrauti, kol jūsų el.paštas nėra patvirtintas, prašome spausti čia kad aktyvuoti jūsų el.paštą", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Negalime patvirtinti jūsų el. adreso, prašom bandyti vėliau.", "confirm-email-already-sent": "Patvirtinimo laiškas išsiųstas, prašome palaukti %1 minute(s) kad išsiųstume kita", diff --git a/public/language/lv/admin/settings/email.json b/public/language/lv/admin/settings/email.json index c74840acb7..a170931724 100644 --- a/public/language/lv/admin/settings/email.json +++ b/public/language/lv/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/lv/error.json b/public/language/lv/error.json index 0438ecc513..224e8d2b7b 100644 --- a/public/language/lv/error.json +++ b/public/language/lv/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Nevar sarunāties, kamēr Tava e-pasta adrese netiek apstiprināta, lūdzu, noklikšķini, lai apstiprinātu savu e-pasta adresi.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Mēs nevarējām apstiprināt Tavu e-pasta adresi, lūdzu, vēlāk mēģini vēlreiz.", "confirm-email-already-sent": "Apstiprinājuma e-pasts ir jau nosūtīts, lūdzu, uzgaidi %1 minūti(-es), lai nosūtītu vēl vienu.", diff --git a/public/language/ms/admin/settings/email.json b/public/language/ms/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/ms/admin/settings/email.json +++ b/public/language/ms/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/ms/error.json b/public/language/ms/error.json index b098e9be5a..d935916ebb 100644 --- a/public/language/ms/error.json +++ b/public/language/ms/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Anda tidak dibenarkan sembang sehingga emel disahkan, sila sahkan emel anda.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Kami tidak dapat memastikan emel anda, sila cuba lagi nanti", "confirm-email-already-sent": "Pengesahan emel telah dihantar, sila tunggu %1 minit() untuk menghantar yang baru.", diff --git a/public/language/nb/admin/settings/email.json b/public/language/nb/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/nb/admin/settings/email.json +++ b/public/language/nb/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/nb/error.json b/public/language/nb/error.json index 15aecf60bb..c1cafd3303 100644 --- a/public/language/nb/error.json +++ b/public/language/nb/error.json @@ -34,8 +34,8 @@ "email-invited": "E-post har allerede fått invitasjon", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Du kan ikke chatte før e-posten din er bekreftet, vennligst klikk her for å bekrefte e-postadressen.", - "email-not-confirmed-email-sent": "Din e-post har enda ikke blitt bekreftet, vennligst sjekk innboksen din for bekreftelsesmailen. Du har ikke tilgang til å skrive innlegg eller chatte før e-posten din er bekreftet.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Vi kunne ikke bekrefte e-posten din, vennligst prøv igjen senere.", "confirm-email-already-sent": "E-post for bekreftelse er allerede sendt, vennligst vent %1 minutt(er) for å sende en til.", diff --git a/public/language/nl/admin/settings/email.json b/public/language/nl/admin/settings/email.json index 9dff8847c2..3588f40700 100644 --- a/public/language/nl/admin/settings/email.json +++ b/public/language/nl/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/nl/error.json b/public/language/nl/error.json index 4a59172cd9..a13dbcc830 100644 --- a/public/language/nl/error.json +++ b/public/language/nl/error.json @@ -34,8 +34,8 @@ "email-invited": "E-mail was reeds uitgenodigd", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Het gebruik van chatfunctionaliteit is pas toegestaan na validatie van het e-mailadres.", - "email-not-confirmed-email-sent": "Je e-mailadres is nog niet bevestigd, kijk of je de bevestigingsmail hebt ontvangen. Tot je e-mailadres is bevestigd kun je geen berichten plaatsen of aan chats deelnemen.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Helaas kon het e-mailadres niet bevestigd worden, probeer het later nog eens.", "confirm-email-already-sent": "Bevestigingsmail is zojuist al verzonden, wacht alsjeblieft %1 minuut (minuten) voordat je opnieuw een bevestigingsmail aanvraagt.", diff --git a/public/language/pl/admin/settings/email.json b/public/language/pl/admin/settings/email.json index a620423653..76895b0536 100644 --- a/public/language/pl/admin/settings/email.json +++ b/public/language/pl/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/pl/error.json b/public/language/pl/error.json index e43f252e9e..90860a6ba5 100644 --- a/public/language/pl/error.json +++ b/public/language/pl/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Nie możesz prowadzić rozmów, dopóki twój email nie zostanie potwierdzony. Kliknij tutaj, aby potwierdzić swój email.", - "email-not-confirmed-email-sent": "Twój e-mail nie został jeszcze potwierdzony, sprawdź swoją skrzynkę pocztową, aby znaleźć e-mail z potwierdzeniem. Nie będziesz mógł dodawać postów ani czatować, dopóki Twój adres e-mail nie zostanie potwierdzony.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Nie byliśmy w stanie potwierdzić Twojego adresu e-mail. Spróbuj później.", "confirm-email-already-sent": "Email potwierdzający został już wysłany, proszę odczekaj jeszcze %1 minut(y), aby wysłać kolejny.", diff --git a/public/language/pt-BR/admin/settings/email.json b/public/language/pt-BR/admin/settings/email.json index c7ade2cc29..ca02b536d0 100644 --- a/public/language/pt-BR/admin/settings/email.json +++ b/public/language/pt-BR/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/pt-BR/error.json b/public/language/pt-BR/error.json index cf339b56fb..07b0e0ff18 100644 --- a/public/language/pt-BR/error.json +++ b/public/language/pt-BR/error.json @@ -34,8 +34,8 @@ "email-invited": "O email já foi convidado", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Você não está habilitado a conversar até que seu email seja confirmado, por favor clique aqui para confirmar seu email.", - "email-not-confirmed-email-sent": "Seu e-mail ainda não foi confirmado, verifique sua caixa de entrada para o e-mail de confirmação. Você não poderá postar ou usar o chat até que seu e-mail seja confirmado.", - "no-email-to-confirm": "Sua conta não tem um email definido. Um email é necessário para recuperação de conta. Clique aqui para definir um email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Nós não pudemos confirmar seu email, por gentileza tente novamente mais tarde.", "confirm-email-already-sent": "O email de confirmação já foi enviado, por favor aguarde %1 minuto(s) para enviar outro.", diff --git a/public/language/pt-PT/admin/settings/email.json b/public/language/pt-PT/admin/settings/email.json index 102a3b114f..8e9e871abc 100644 --- a/public/language/pt-PT/admin/settings/email.json +++ b/public/language/pt-PT/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/pt-PT/error.json b/public/language/pt-PT/error.json index 7b9fb823cc..2750c5b577 100644 --- a/public/language/pt-PT/error.json +++ b/public/language/pt-PT/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Não podes utilizar o chat enquanto não confirmares o teu e-mail, por favor clica aqui para confirmares o teu e-mail.", - "email-not-confirmed-email-sent": "O teu e-mail ainda não foi confirmado, por favor verifica a tua caixa de entrada para obteres o e-mail de confirmação. Não poderás publicar ou conversar até que o teu e-mail seja confirmado.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Não conseguimos confirmar o teu e-mail, por favor tenta mais tarde.", "confirm-email-already-sent": "O e-mail de confirmação já foi enviado, por favor espera %1 minuto(s) para enviares outro.", diff --git a/public/language/ro/admin/settings/email.json b/public/language/ro/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/ro/admin/settings/email.json +++ b/public/language/ro/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/ro/error.json b/public/language/ro/error.json index 41ca4cd6dd..d21bdd06c4 100644 --- a/public/language/ro/error.json +++ b/public/language/ro/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Nu vei putea trimite mesaje daca email-ul tau nu e confirmat, click aici sa il confirmi.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Mail-ul tau nu a putut fi confirmat, te rog incearca mai tarziu.", "confirm-email-already-sent": "Email-ul de confirmare ti-a fost trimis, asteapta te rog %1 minut(e) ca sa trimiti inca unul.", diff --git a/public/language/ru/admin/settings/email.json b/public/language/ru/admin/settings/email.json index 8a1a595fc2..05028e66f2 100644 --- a/public/language/ru/admin/settings/email.json +++ b/public/language/ru/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/ru/error.json b/public/language/ru/error.json index 64d72ba958..20a8a9dbe0 100644 --- a/public/language/ru/error.json +++ b/public/language/ru/error.json @@ -34,8 +34,8 @@ "email-invited": "Электронная почта уже была приглашена", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Вы не можете оставлять сообщения, пока ваша электронная почта не подтверждена. Отправить письмо с кодом подтверждения повторно.", - "email-not-confirmed-email-sent": "Ваш адрес электронной почты ещё не подтверждён. Пожалуйста, проверьте ваш почтовый ящик и пройдите по ссылке в письме с кодом подтверждения. Пока ваш e-mail не подтверждён, вы не можете пользоваться чатом или публиковать сообщения.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "По техническим причинам мы не можем подтвердить ваш адрес электронной почты. Приносим вам наши извинения, пожалуйста, попробуйте позже.", "confirm-email-already-sent": "Сообщение для подтверждения регистрации уже выслано на ваш адрес электронной почты. Повторная отправка возможна через %1 мин.", diff --git a/public/language/rw/admin/settings/email.json b/public/language/rw/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/rw/admin/settings/email.json +++ b/public/language/rw/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/rw/error.json b/public/language/rw/error.json index 616831f5cd..51ef2785a9 100644 --- a/public/language/rw/error.json +++ b/public/language/rw/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Ntabwo uremererwa kuganirira mu gikari kuko email yawe itari yemezwa. Kanda hano kugirango wemeze email yawe. ", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Ntabwo email yawe yabashije kwemezwa. Ongera ugerageze mu bundi buryo. ", "confirm-email-already-sent": "Email yo kwemeza yamaze koherezwa. Tegereza iminota (umunota) %1 mbere yo kohereza indi. ", diff --git a/public/language/sc/admin/settings/email.json b/public/language/sc/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/sc/admin/settings/email.json +++ b/public/language/sc/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/sc/error.json b/public/language/sc/error.json index 55f49fe028..6eb0983661 100644 --- a/public/language/sc/error.json +++ b/public/language/sc/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "You are unable to chat until your email is confirmed, please click here to confirm your email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "We could not confirm your email, please try again later.", "confirm-email-already-sent": "Confirmation email already sent, please wait %1 minute(s) to send another one.", diff --git a/public/language/sk/admin/settings/email.json b/public/language/sk/admin/settings/email.json index 7d4f8801ba..894bd512e3 100644 --- a/public/language/sk/admin/settings/email.json +++ b/public/language/sk/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/sk/error.json b/public/language/sk/error.json index d757b9ca06..81d83d10ab 100644 --- a/public/language/sk/error.json +++ b/public/language/sk/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Nemôžete vytvoriť konverzáciu pokiaľ Váš e-mail nebude overený. Prosím kliknite sem, pre overenie Vášho e-mailu.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Momentálne nemôžeme overiť Váš e-mail, prosím zopakujte to neskôr.", "confirm-email-already-sent": "Overovací e-mail už bol odoslaný. Prosím počkajte %1 minút(y) k odoslaniu ďalšieho.", diff --git a/public/language/sl/admin/settings/email.json b/public/language/sl/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/sl/admin/settings/email.json +++ b/public/language/sl/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/sl/error.json b/public/language/sl/error.json index eaccb961dd..e87f4d0f4e 100644 --- a/public/language/sl/error.json +++ b/public/language/sl/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Ne morete klepetati, dokler ne potrdite svojega e-poštnega naslova. Prosimo, kliknite tu za potrditev e-poštnega naslova.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Potrditev vašega e-poštnega naslova ni uspela. Prosimo, poskusite ponovno pozneje.", "confirm-email-already-sent": "Potrditveno e-sporočilo je že bilo poslano. Prosimo, počakajte %1 min za ponovno pošiljanje.", diff --git a/public/language/sr/admin/settings/email.json b/public/language/sr/admin/settings/email.json index 6b883faa8f..f0a4584fb4 100644 --- a/public/language/sr/admin/settings/email.json +++ b/public/language/sr/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/sr/error.json b/public/language/sr/error.json index 891461b2d3..d5a1e83818 100644 --- a/public/language/sr/error.json +++ b/public/language/sr/error.json @@ -34,8 +34,8 @@ "email-invited": "Е-пошта је већ позвана", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Није вам дозвољено да ћаскате док не потврдите вашу е-пошту, кликните овде да то учините.", - "email-not-confirmed-email-sent": "Ваша е-пошта још увек није потврђена, проверите ваше пријемно сандуче. Неће вам бити дозвољено да шаљете поруке или ћаскате док не потврдите е-пошту.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Потврда е-поште није успела, молимо вас да покушате касније.", "confirm-email-already-sent": "Е-порука за потврду је већ послата, молимо вас да сачекате %1 минут(а) да бисте послали други.", diff --git a/public/language/sv/admin/settings/email.json b/public/language/sv/admin/settings/email.json index df7fb57417..381ab387df 100644 --- a/public/language/sv/admin/settings/email.json +++ b/public/language/sv/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/sv/error.json b/public/language/sv/error.json index 5ca430b175..5b65ecb344 100644 --- a/public/language/sv/error.json +++ b/public/language/sv/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Du kan ej använda chatten förrän din epostadress har blivit bekräftad, var god klicka här för att bekräfta din epostadress.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Vi kunde ej bekräfta din epostadress, var god försök igen senare.", "confirm-email-already-sent": "Bekräftningsbrev redan skickat, var god vänta %1 minut(er) innan du skickar ett nytt.", diff --git a/public/language/th/admin/settings/email.json b/public/language/th/admin/settings/email.json index 1121da568a..65f579d28c 100644 --- a/public/language/th/admin/settings/email.json +++ b/public/language/th/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/th/error.json b/public/language/th/error.json index 7289c2f21d..17adfbe6b9 100644 --- a/public/language/th/error.json +++ b/public/language/th/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "คุณไม่สามารถแชทได้จนกว่าอีเมล์ของคุณจะได้รับการยืนยัน กรุณาคลิกที่นี่เพื่อยืนยันอีกมเมล์ของคุณ", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You won't be able to post or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "เราไม่สามารถยืนยันอีเมลของคุณ ณ ขณะนี้ กรุณาลองใหม่อีกครั้งภายหลัง", "confirm-email-already-sent": "อีเมล์ยืนยันตัวตนถูกส่งไปยังคุณเรียบร้อยแล้ว กรุณารอ %1 นาที(s) ก่อนการตัดสินใจส่งอีกครั้ง", diff --git a/public/language/tr/admin/settings/email.json b/public/language/tr/admin/settings/email.json index 40188114cf..3d77ac0d53 100644 --- a/public/language/tr/admin/settings/email.json +++ b/public/language/tr/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/tr/error.json b/public/language/tr/error.json index e976ac210a..28e7e76b52 100644 --- a/public/language/tr/error.json +++ b/public/language/tr/error.json @@ -34,8 +34,8 @@ "email-invited": "E-posta halihazırda davet edilmiş", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "E-postanız onaylanana kadar sohbet edemezsiniz, onaylamak için lütfen buraya tıklayın.", - "email-not-confirmed-email-sent": "E-posta adresiniz henüz onaylanmamış, lütfen onay e-postası için gelen kutunuzu kontrol ediniz. E-posta adresinizi onaylayana kadar foruma ileti gönderemeyeceksiniz veya sohbet edemeyeceksiniz!", - "no-email-to-confirm": "Hesabınızda bir e-posta adresi bulunmuyor. Hesabınızın kurtarılması için bir e-posta gerekecek. E-posta adresinizi girmek için tıklayın.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "\"%1\" kullanıcısı bir e-posta belirlememiş.", "email-confirm-failed": "E-posta adresinizi doğrulayamıyoruz. Lütfen daha sonra tekrar deneyin.", "confirm-email-already-sent": "E-posta onayı zaten gönderilmiş, yeni bir onay göndermek için lütfen %1 dakika bekleyin.", diff --git a/public/language/uk/admin/settings/email.json b/public/language/uk/admin/settings/email.json index 09ff7f14fb..912ca7528a 100644 --- a/public/language/uk/admin/settings/email.json +++ b/public/language/uk/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/uk/error.json b/public/language/uk/error.json index 3f4df7de8f..eae362e14b 100644 --- a/public/language/uk/error.json +++ b/public/language/uk/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "Ви не можете користуватися чатом поки ваша електронна пошта не буде підтверджена, натисніть тут, щоб це зробити.", - "email-not-confirmed-email-sent": "Ваша електронна адреса ще не була підтверджена, будь-ласка перевірте свою поштову скриньку. Ви не зможете постити або чатитись до того як ваш емейл підтверджено.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "Ми не можемо підтвердити вашу електронну пошту, будь ласка, спробуйте пізніше.", "confirm-email-already-sent": "Підтвердження по електронній пошті вже було надіслано, зачекайте, будь ласка, %1 хвилин(и), щоб відправити ще одне. ", diff --git a/public/language/vi/admin/settings/email.json b/public/language/vi/admin/settings/email.json index 7f11f8260e..066d64e9f7 100644 --- a/public/language/vi/admin/settings/email.json +++ b/public/language/vi/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Bắt buộc người dùng mới phải điền địa chỉ email", "require-email-address-warning": "Mặc định, người dùng có thể chọn không nhập địa chỉ email. Bật tùy chọn này nghĩa là họ buộc phải nhập địa chỉ email để đăng ký. Việc này không chắc người dùng sẽ nhập địa chỉ email thực, hoặc không phải địa chỉ mà họ sở hữu.", "include-unverified-emails": "Gửi email đến những người nhận chưa xác nhận rõ ràng email của họ", - "include-unverified-warning": "Theo mặc định, người dùng có email được liên kết với tài khoản của họ đã được xác minh, nhưng có những trường hợp không phải như vậy (ví dụ: đăng nhập SSO, người dùng phổ thông, v.v.). Bạn tự chịu rủi ro khi bật cài đặt này – gửi email đến các địa chỉ chưa được xác minh có thể vi phạm luật chống thư rác trong khu vực." + "include-unverified-warning": "Theo mặc định, người dùng có email được liên kết với tài khoản của họ đã được xác minh, nhưng có những trường hợp không phải như vậy (ví dụ: đăng nhập SSO, người dùng phổ thông, v.v.). Bạn tự chịu rủi ro khi bật cài đặt này – gửi email đến các địa chỉ chưa được xác minh có thể vi phạm luật chống thư rác trong khu vực.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/vi/error.json b/public/language/vi/error.json index caf3958071..6dd9b00f2d 100644 --- a/public/language/vi/error.json +++ b/public/language/vi/error.json @@ -34,8 +34,8 @@ "email-invited": "Email đã được mời", "email-not-confirmed": "Đăng trong một số danh mục hoặc chủ đề được bật sau khi email của bạn được xác nhận, vui lòng nhấp vào đây để gửi email xác nhận.", "email-not-confirmed-chat": "Bạn không thể trò chuyện cho đến khi email của bạn được xác nhận, vui lòng nhấp vào đây để xác nhận email của bạn.", - "email-not-confirmed-email-sent": "Email của bạn vẫn chưa được xác nhận, vui lòng kiểm tra hộp thư đến của bạn. Bạn sẽ không thể đăng hoặc trò chuyện cho đến khi email được xác nhận.", - "no-email-to-confirm": "Tài khoản của bạn không có email. Email là cần thiết để khôi phục tài khoản. Vui lòng bấm vào đây để nhập email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "Người dùng \"%1\" chưa đặt email.", "email-confirm-failed": "Chúng tôi không thể xác nhận email của bạn, vui lòng thử lại sau.", "confirm-email-already-sent": "Email xác nhận đã được gửi, vui lòng chờ %1 phút để yêu cầu gửi lại.", diff --git a/public/language/zh-CN/admin/settings/email.json b/public/language/zh-CN/admin/settings/email.json index 1e3808ca2e..5afd0ca782 100644 --- a/public/language/zh-CN/admin/settings/email.json +++ b/public/language/zh-CN/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/zh-CN/error.json b/public/language/zh-CN/error.json index b1d890d5bf..1c087addf7 100644 --- a/public/language/zh-CN/error.json +++ b/public/language/zh-CN/error.json @@ -34,8 +34,8 @@ "email-invited": "已通过电子邮件进行邀请", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "您的电子邮箱尚未确认,无法聊天,请点击这里确认您的电子邮箱。", - "email-not-confirmed-email-sent": "您的电子邮件账户尚未确认,请检查您的收件箱。在电子邮件帐户被确认前您不能发帖和聊天。", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "我们无法确认您的电子邮箱,请重试", "confirm-email-already-sent": "确认邮件已发出,如需重新发送请等待 %1 分钟后再试。", diff --git a/public/language/zh-TW/admin/settings/email.json b/public/language/zh-TW/admin/settings/email.json index b706a17948..bddc247003 100644 --- a/public/language/zh-TW/admin/settings/email.json +++ b/public/language/zh-TW/admin/settings/email.json @@ -40,5 +40,7 @@ "require-email-address": "Require new users to specify an email address", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws." + "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", + "prompt": "Prompt users to enter or confirm their emails", + "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." } diff --git a/public/language/zh-TW/error.json b/public/language/zh-TW/error.json index 20482032e5..00e6cc398c 100644 --- a/public/language/zh-TW/error.json +++ b/public/language/zh-TW/error.json @@ -34,8 +34,8 @@ "email-invited": "Email was already invited", "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", "email-not-confirmed-chat": "您的電子信箱尚未確認,無法聊天,請點擊這裡確認您的電子信箱。", - "email-not-confirmed-email-sent": "您的電子信箱尚未確認,請檢查您的收件匣。在電子信箱被確認前您不能貼文和聊天。", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", + "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", "user-doesnt-have-email": "User \"%1\" does not have an email set.", "email-confirm-failed": "我們無法確認您的電子信箱,請重試", "confirm-email-already-sent": "確認郵件已發出,如需重新發送請等待 %1 分鐘後再試。", From 25ebbd6563931a9ed548254eb10ae143ac060356 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 26 Oct 2021 14:51:49 -0400 Subject: [PATCH 292/412] fix: windows tests --- test/i18n.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/i18n.js b/test/i18n.js index 692232b305..af066098f9 100644 --- a/test/i18n.js +++ b/test/i18n.js @@ -15,7 +15,7 @@ describe('i18n', () => { before(async () => { folders = await fs.promises.readdir(path.resolve(__dirname, '../public/language')); - folders.shift(); // remove README.md from list of folders to check + folders = folders.filter(f => f !== 'README.md'); }); it('should contain folders named after the language code', async () => { From c7e078d4950ef874f73f4d8668a88d6d31c11e9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 26 Oct 2021 15:51:42 -0400 Subject: [PATCH 293/412] refactor: dont save partial searches --- src/controllers/search.js | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/controllers/search.js b/src/controllers/search.js index 76a34d1e39..004fe67e3b 100644 --- a/src/controllers/search.js +++ b/src/controllers/search.js @@ -97,12 +97,26 @@ searchController.search = async function (req, res, next) { res.render('search', searchData); }; +const searches = {}; + async function recordSearch(data) { const { query, searchIn } = data; if (query) { const cleanedQuery = String(query).trim().toLowerCase().substr(0, 255); if (['titles', 'titlesposts', 'posts'].includes(searchIn) && cleanedQuery.length > 2) { - await db.sortedSetIncrBy('searches:all', 1, cleanedQuery); + searches[data.uid] = searches[data.uid] || { timeoutId: 0, queries: [] }; + searches[data.uid].queries.push(cleanedQuery); + if (searches[data.uid].timeoutId) { + clearTimeout(searches[data.uid].timeoutId); + } + searches[data.uid].timeoutId = setTimeout(async () => { + const copy = searches[data.uid].queries.slice(); + const filtered = searches[data.uid].queries.filter( + q => !copy.find(query => query.startsWith(q) && query.length > q.length) + ); + await Promise.all(filtered.map(query => db.sortedSetIncrBy('searches:all', 1, query))); + delete searches[data.uid]; + }, 5000); } } } From c428ba80aa85bcf9bacfa370ff934f1f5a8ee0d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 26 Oct 2021 16:20:24 -0400 Subject: [PATCH 294/412] refactor: wider value field --- src/views/admin/extend/rewards.tpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/views/admin/extend/rewards.tpl b/src/views/admin/extend/rewards.tpl index 78c11e1445..e53b639b2d 100644 --- a/src/views/admin/extend/rewards.tpl +++ b/src/views/admin/extend/rewards.tpl @@ -17,14 +17,14 @@

    -
    +
    -
    +
    From 7c2ecb1234c7111087e554f9bca3a0aa974b6137 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Wed, 27 Oct 2021 01:02:14 +0000 Subject: [PATCH 295/412] fix(deps): update dependency nodebb-rewards-essentials to v0.2.0 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 970e165d84..93baeb7251 100644 --- a/install/package.json +++ b/install/package.json @@ -91,7 +91,7 @@ "nodebb-plugin-markdown": "8.14.4", "nodebb-plugin-mentions": "2.14.1", "nodebb-plugin-spam-be-gone": "0.7.10", - "nodebb-rewards-essentials": "0.1.5", + "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", "nodebb-theme-persona": "11.2.18", "nodebb-theme-slick": "1.4.14", From 8d4bb8bbbede04d2a5c0081c028a9653f4407d4f Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Wed, 27 Oct 2021 02:01:30 +0000 Subject: [PATCH 296/412] chore(deps): update dependency lint-staged to v11.2.6 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 93baeb7251..b158f0db09 100644 --- a/install/package.json +++ b/install/package.json @@ -152,7 +152,7 @@ "grunt-contrib-watch": "1.1.0", "husky": "7.0.4", "jsdom": "18.0.0", - "lint-staged": "11.2.5", + "lint-staged": "11.2.6", "mocha": "9.1.3", "mocha-lcov-reporter": "1.3.0", "mockdate": "3.0.5", From f2bf33a28c147dcb0186c255c0a94a0a8779fe06 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 27 Oct 2021 09:07:24 +0000 Subject: [PATCH 297/412] Latest translations and fallbacks --- public/language/bg/admin/settings/email.json | 4 ++-- public/language/bg/error.json | 4 ++-- public/language/he/user.json | 2 +- public/language/it/admin/dashboard.json | 10 +++++----- public/language/it/admin/manage/categories.json | 2 +- public/language/it/admin/manage/registration.json | 4 ++-- public/language/it/admin/menu.json | 6 +++--- public/language/it/admin/settings/general.json | 8 ++++---- public/language/it/admin/settings/notifications.json | 2 +- public/language/it/admin/settings/post.json | 12 ++++++------ public/language/it/admin/settings/user.json | 2 +- public/language/it/notifications.json | 6 +++--- public/language/it/pages.json | 2 +- public/language/it/post-queue.json | 4 ++-- 14 files changed, 34 insertions(+), 34 deletions(-) diff --git a/public/language/bg/admin/settings/email.json b/public/language/bg/admin/settings/email.json index 8bd62c410a..74d2d26ce1 100644 --- a/public/language/bg/admin/settings/email.json +++ b/public/language/bg/admin/settings/email.json @@ -41,6 +41,6 @@ "require-email-address-warning": "По подразбиране потребителите могат да не въвеждат адрес на е-поща. Ако включите това, те задължително ще трябва да предоставят е-поща, за да могат да се регистрират. Това не означава, че потребителят ще въведе съществуваща е-поща, нито че тя ще е негова.", "include-unverified-emails": "Изпращане на е-писма към получатели, които не са потвърдили изрично е-пощата си", "include-unverified-warning": "За потребителите, които имат свързана е-поща с регистрацията си, тя се смята за потвърдена. Но има ситуации, в които това не е така (например при ползване на регистрация от друга система, но и в други случаи), Включете тази настройка на собствен риск – изпращането на е-писма към непотвърдени адреси може да нарушава определени местни закони против нежеланата поща.", - "prompt": "Prompt users to enter or confirm their emails", - "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." + "prompt": "Подсещане на потребителите да въведат или потвърдят е-пощата си", + "prompt-help": "Ако потребител няма зададена е-поща, или ако тя не е потвърдена, на екрана му ще се покаже предупредително съобщение." } diff --git a/public/language/bg/error.json b/public/language/bg/error.json index 104b4a3d92..339a78d653 100644 --- a/public/language/bg/error.json +++ b/public/language/bg/error.json @@ -34,8 +34,8 @@ "email-invited": "На тази е-поща вече е била изпратена покана", "email-not-confirmed": "Публикуването в някои категории и теми ще бъде възможно едва след като е-пощата Ви бъде потвърдена. Щръкнете тук, за да Ви изпратим е-писмо за потвърждение.", "email-not-confirmed-chat": "Няма да можете да пишете в разговори, докато е-пощата Ви не бъде потвърдена. Моля, натиснете тук, за да потвърдите е-пощата си.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Вашата е-поща все още не е потвърдена. Моля, проверете входящата си кутия за писмото за потвърждение. Възможно е да не можете да публикувате съобщения или да пишете в разговори, докато е-пощата Ви не бъде потвърдена.", + "no-email-to-confirm": "Нямате зададена е-поща. Тя е необходима за възстановяването на акаунта в случай на проблем, а може и да се изисква, за да пишете в някои категории. Натиснете тук, за да въведете е-поща.", "user-doesnt-have-email": "Потребителят „%1“ няма зададена е-поща.", "email-confirm-failed": "Не успяхме да потвърдим е-пощата Ви. Моля, опитайте отново по-късно.", "confirm-email-already-sent": "Е-писмото за потвърждение вече е изпратено. Моля, почакайте още %1 минута/и, преди да изпратите ново.", diff --git a/public/language/he/user.json b/public/language/he/user.json index 0333d7d3dd..47dc53acd1 100644 --- a/public/language/he/user.json +++ b/public/language/he/user.json @@ -94,7 +94,7 @@ "digest_off": "כבוי", "digest_daily": "יומי", "digest_weekly": "שבועי", - "digest_biweekly": "Bi-Weekly", + "digest_biweekly": "דו שבועי", "digest_monthly": "חודשי", "has_no_follower": "למשתמש זה אין עוקבים :(", "follows_no_one": "משתמש זה אינו עוקב אחרי אחרים :(", diff --git a/public/language/it/admin/dashboard.json b/public/language/it/admin/dashboard.json index 9a3dca1426..329c11dd7c 100644 --- a/public/language/it/admin/dashboard.json +++ b/public/language/it/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Totale", "active-users.connections": "Connessioni", - "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest-registered-users": "Ospite vs Utenti Registrati", + "guest": "Ospite", "registered": "Registrati", "user-presence": "Presenza utente", @@ -68,7 +68,7 @@ "unread": "Non letto", "high-presence-topics": "Alta presenza discussioni", - "popular-searches": "Popular Searches", + "popular-searches": "Ricerche popolari", "graphs.page-views": "Pagine viste", "graphs.page-views-registered": "Pagine viste Registrati", @@ -76,14 +76,14 @@ "graphs.page-views-bot": "Pagine viste Bot", "graphs.unique-visitors": "Visitatori Unici", "graphs.registered-users": "Utenti Registrati", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "Utenti ospiti", "last-restarted-by": "Ultimo riavvio di", "no-users-browsing": "Nessun utente sta navigando", "back-to-dashboard": "Torna alla dashboard", "details.no-users": "Nessun utente si è iscritto nell'arco di tempo selezionato", "details.no-topics": "Nessuna discussione è stata postata nell'arco di tempo selezionato", - "details.no-searches": "No searches have been made yet", + "details.no-searches": "Nessuna ricerca è ancora stata fatta", "details.no-logins": "Non sono stati registrati accessi nell'arco di tempo selezionato", "details.logins-static": "NodeBB salva solo i dati di sessione per %1 giorni, quindi la tabella qui sotto mostrerà solo le sessioni attive più recenti", "details.logins-login-time": "Tempo di accesso" diff --git a/public/language/it/admin/manage/categories.json b/public/language/it/admin/manage/categories.json index 5166ed1b90..b46897636f 100644 --- a/public/language/it/admin/manage/categories.json +++ b/public/language/it/admin/manage/categories.json @@ -12,7 +12,7 @@ "ext-link": "Link esterni", "subcategories-per-page": "Sottocategorie per pagina", "is-section": "Tratta questa categoria come una sezione", - "post-queue": "Post in attesa", + "post-queue": "Coda post", "tag-whitelist": "Whitelist tag", "upload-image": "Caricamento Immagine", "delete-image": "Rimuove", diff --git a/public/language/it/admin/manage/registration.json b/public/language/it/admin/manage/registration.json index 68e491a73d..11d0329b87 100644 --- a/public/language/it/admin/manage/registration.json +++ b/public/language/it/admin/manage/registration.json @@ -1,6 +1,6 @@ { - "queue": "Attesa", - "description": "Non ci sono utenti in attesa di registrazione.
    Per abilitare questa funzione, vai in Impostazioni → Utente → Registrazione Utente e imposta Tipo Registrazione su \"Approvazione Amministratore\".", + "queue": "Coda", + "description": "Non ci sono utenti nella coda di registrazione.
    Per abilitare questa funzione, vai in Impostazioni → Utente → Registrazione Utente e imposta Tipo Registrazione su \"Approvazione Amministratore\".", "list.name": "Nome", "list.email": "Email", diff --git a/public/language/it/admin/menu.json b/public/language/it/admin/menu.json index 9506af8a68..8851052e87 100644 --- a/public/language/it/admin/menu.json +++ b/public/language/it/admin/menu.json @@ -4,7 +4,7 @@ "dashboard/logins": "Accessi", "dashboard/users": "Utenti", "dashboard/topics": "Discussioni", - "dashboard/searches": "Searches", + "dashboard/searches": "Ricerche", "section-general": "Generale", "section-manage": "Gestisci", @@ -13,8 +13,8 @@ "manage/tags": "Tabs", "manage/users": "Utenti", "manage/admins-mods": "Amministratori e Moderatori", - "manage/registration": "Attesa di registrazione", - "manage/post-queue": "Post in attesa", + "manage/registration": "Coda di registrazione", + "manage/post-queue": "Coda post", "manage/groups": "Gruppi", "manage/ip-blacklist": "Lista degli IP bloccati", "manage/uploads": "Uploads", diff --git a/public/language/it/admin/settings/general.json b/public/language/it/admin/settings/general.json index ed15967d42..c556adf46c 100644 --- a/public/language/it/admin/settings/general.json +++ b/public/language/it/admin/settings/general.json @@ -3,9 +3,9 @@ "title": "Titolo Sito", "title.short": "Titolo abbreviato", "title.short-placeholder": "Se non specifichi un titolo abbreviato, verrà utilizzato il titolo completo", - "title.url": "Title Link URL", + "title.url": "Link URL Titolo", "title.url-placeholder": "L'URL del titolo del sito", - "title.url-help": "When the title is clicked, send users to this address. If left blank, user will be sent to the forum index.
    Note: This is not the external URL used in emails, etc. That is set by the url property in config.json", + "title.url-help": "Quando il titolo viene cliccato, invia gli utenti a questo indirizzo. Se lasciato vuoto, l'utente sarà inviato all'indice del forum.
    Nota: Questo non è l'URL esterno usato nelle email, ecc. Questo è impostato dalla proprietà url in config.json", "title.name": "Il Nome della Comunità", "title.show-in-header": "Mostra Titolo Sito nell'Intestazione", "browser-title": "Titolo Browser", @@ -20,9 +20,9 @@ "logo.image": "Immagine", "logo.image-placeholder": "Percorso del logo da visualizzare sull'intestazione del forum", "logo.upload": "Carica", - "logo.url": "Logo Link URL", + "logo.url": "Link URL Logo", "logo.url-placeholder": "L'URL del logo del sito", - "logo.url-help": "When the logo is clicked, send users to this address. If left blank, user will be sent to the forum index.
    Note: This is not the external URL used in emails, etc. That is set by the url property in config.json", + "logo.url-help": "Quando il logo viene cliccato, invia gli utenti a questo indirizzo. Se lasciato vuoto, l'utente sarà inviato all'indice del forum.
    Nota: Questo non è l'URL esterno usato nelle email, ecc. Questo è impostato dalla proprietà url in config.json", "logo.alt-text": "Testo alternativo", "log.alt-text-placeholder": "Testo alternativo per l'accessibilità", "favicon": "Favicon", diff --git a/public/language/it/admin/settings/notifications.json b/public/language/it/admin/settings/notifications.json index 7eec59d24a..9574902ce0 100644 --- a/public/language/it/admin/settings/notifications.json +++ b/public/language/it/admin/settings/notifications.json @@ -3,5 +3,5 @@ "welcome-notification": "Notifica di benvenuto", "welcome-notification-link": "Collegamento a Notifica di benvenuto", "welcome-notification-uid": "Notifica di benvenuto utente (UID)", - "post-queue-notification-uid": "Post Queue User (UID)" + "post-queue-notification-uid": "Coda post utente (UID)" } \ No newline at end of file diff --git a/public/language/it/admin/settings/post.json b/public/language/it/admin/settings/post.json index aaecd61292..5cbea6601b 100644 --- a/public/language/it/admin/settings/post.json +++ b/public/language/it/admin/settings/post.json @@ -7,14 +7,14 @@ "sorting.most-posts": "Più Post", "sorting.topic-default": "Ordinamento Discussione Predefinito", "length": "Lunghezza Post", - "post-queue": "Coda Post", + "post-queue": "Coda post", "restrictions": "Restrizioni pubblicazione", "restrictions-new": "Restrizioni Nuovo Utente", - "restrictions.post-queue": "Abilita post in attesa", + "restrictions.post-queue": "Abilita coda post", "restrictions.post-queue-rep-threshold": "Reputazione necessaria a superare la coda dei post", "restrictions.groups-exempt-from-post-queue": "Seleziona i gruppi che dovrebbero essere esclusi dalla coda dei post", "restrictions-new.post-queue": "Abilita le restrizioni per i nuovi utenti", - "restrictions.post-queue-help": "Abilitando la coda dei post, i post dei nuovi utenti, verranno messi in coda per l'approvazione", + "restrictions.post-queue-help": "Abilitando la coda dei post, i post dei nuovi utenti, saranno messi in coda per l'approvazione", "restrictions-new.post-queue-help": "Abilitando le restrizioni per i nuovi utenti verranno impostate le restrizioni sui post dei nuovi utenti", "restrictions.seconds-between": "Numero di secondi tra i post", "restrictions.seconds-between-new": "Numero di secondi tra i post per i nuovi utenti", @@ -56,9 +56,9 @@ "composer.show-help": "Mostra la scheda \"Aiuto\"", "composer.enable-plugin-help": "Consenti ai plug-in di aggiungere contenuti alla scheda Guida", "composer.custom-help": "Testo di aiuto personalizzato", - "backlinks": "Backlinks", - "backlinks.enabled": "Enable topic backlinks", - "backlinks.help": "If a post references another topic, a link back to the post will be inserted into the referenced topic at that point in time.", + "backlinks": "Backlink", + "backlinks.enabled": "Abilita backlink discussione", + "backlinks.help": "Se un post fa riferimento ad un altra discussione, un link al post sarà inserito nella discussione di riferimento in quel momento.", "ip-tracking": "Monitoraggio IP", "ip-tracking.each-post": "Traccia l'indirizzo IP per ogni post", "enable-post-history": "Abilita Cronologia post" diff --git a/public/language/it/admin/settings/user.json b/public/language/it/admin/settings/user.json index 13f3f5f9ea..ed79c8ebc3 100644 --- a/public/language/it/admin/settings/user.json +++ b/public/language/it/admin/settings/user.json @@ -43,7 +43,7 @@ "registration-type.admin-invite-only": "Solo invito per Amministratori", "registration-type.disabled": "Niente registrazione", "registration-type.help": "Normale: gli utenti possono registrarsi dalla pagina/di registrazione.
    \nSolo invito: gli utenti possono invitare altri dalla pagina utenti.
    \nSolo su invito amministratore: solo gli amministratori possono invitare altri utenti edalle pagine amministratore/gestione/utenti.
    \nNessuna registrazione - Nessuna registrazione dell'utente.
    ", - "registration-approval-type.help": "Normale: gli utenti vengono registrati immediatamente.
    \nApprovazione amministratore - Le registrazioni degli utenti vengono inserite in una coda di approvazione per amministratori.
    \nApprovazione amministratore per IP - Normale per i nuovi utenti, Approvazione amministratore per indirizzi IP che dispongono già di un account.
    ", + "registration-approval-type.help": "Normale: gli utenti vengono registrati immediatamente.
    \nApprovazione amministratore - Le registrazioni degli utenti sono inserite in una coda di approvazione per amministratori.
    \nApprovazione amministratore per IP - Normale per i nuovi utenti, Approvazione amministratore per indirizzi IP che dispongono già di un account.
    ", "registration-queue-auto-approve-time": "Tempo di approvazione automatico", "registration-queue-auto-approve-time-help": "Ore prima che l'utente venga approvato automaticamente. 0 per disabilitare.", "registration-queue-show-average-time": "Mostra agli utenti il tempo medio necessario per approvare un nuovo utente", diff --git a/public/language/it/notifications.json b/public/language/it/notifications.json index 0fdc2b79e5..869f711a7c 100644 --- a/public/language/it/notifications.json +++ b/public/language/it/notifications.json @@ -48,7 +48,7 @@ "posts-exported": "%1 post esportati, clicca per scaricare", "uploads-exported": "%1 caricamenti esportati, clicca per scaricare", "users-csv-exported": "Utenti esportati in CSV, clicca per scaricare", - "post-queue-accepted": "Your queued post has been accepted. Click here to see your post.", + "post-queue-accepted": "Il tuo post in coda è stato accettato. Clicca qui per vedere il tuo post.", "post-queue-rejected": "Il tuo post in coda è stato rifiutato.", "email-confirmed": "Email Confermata", "email-confirmed-message": "Grazie per aver validato la tua email. Il tuo account è ora completamente attivato.", @@ -68,8 +68,8 @@ "notificationType_group-invite": "Quando ricevi un invito ad un gruppo", "notificationType_group-leave": "Quando un utente lascia il gruppo", "notificationType_group-request-membership": "Quando qualcuno richiede di iscriversi a un gruppo di tua proprietà", - "notificationType_new-register": "Quando qualcuno è in attesa della registrazione", - "notificationType_post-queue": "Quando un nuovo post è in attesa", + "notificationType_new-register": "Quando qualcuno viene aggiunto alla coda di registrazione", + "notificationType_post-queue": "Quando un nuovo post è in coda", "notificationType_new-post-flag": "Quando un post viene segnalato", "notificationType_new-user-flag": "Quando un utente viene segnalato" } \ No newline at end of file diff --git a/public/language/it/pages.json b/public/language/it/pages.json index fe0bac5bc9..a6f5b08e1f 100644 --- a/public/language/it/pages.json +++ b/public/language/it/pages.json @@ -13,7 +13,7 @@ "moderator-tools": "Strumenti di moderazione", "flagged-content": "Contenuti Segnalati", "ip-blacklist": "Blacklist degli IP", - "post-queue": "Post in attesa", + "post-queue": "Coda post", "users/online": "Utenti Online", "users/latest": "Ultimi Utenti", "users/sort-posts": "Utenti maggiori contributori", diff --git a/public/language/it/post-queue.json b/public/language/it/post-queue.json index b052203795..2835fe4607 100644 --- a/public/language/it/post-queue.json +++ b/public/language/it/post-queue.json @@ -1,7 +1,7 @@ { - "post-queue": "Post in attesa", - "description": "Non ci sono post nella coda della post.
    Per abilitare questa funzione, vai in Impostazioni → Post → Codice post e abilita Post in attesa.", + "post-queue": "Coda post", + "description": "Non ci sono post nella coda dei post.
    Per abilitare questa funzione, vai in Impostazioni → Post → Coda post e abilita Coda post.", "user": "Utente", "category": "Categoria", "title": "Titolo", From 015727855f1b57083685b2dce0114673fadd159c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 27 Oct 2021 09:39:48 -0400 Subject: [PATCH 298/412] fix: remove loading="lazy", fixes inf. scroll loaded images --- public/src/modules/helpers.js | 1 - 1 file changed, 1 deletion(-) diff --git a/public/src/modules/helpers.js b/public/src/modules/helpers.js index b1778c92b1..8f9eb5959e 100644 --- a/public/src/modules/helpers.js +++ b/public/src/modules/helpers.js @@ -334,7 +334,6 @@ 'alt="' + userObj.username + '"', 'title="' + userObj.username + '"', 'data-uid="' + userObj.uid + '"', - 'loading="lazy"', ]; const styles = []; classNames = classNames || ''; From 3d1cf168f269d674c83904e12ea2c33693ae25b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 27 Oct 2021 09:52:46 -0400 Subject: [PATCH 299/412] revert: lazy load --- public/src/modules/helpers.js | 1 + 1 file changed, 1 insertion(+) diff --git a/public/src/modules/helpers.js b/public/src/modules/helpers.js index 8f9eb5959e..b1778c92b1 100644 --- a/public/src/modules/helpers.js +++ b/public/src/modules/helpers.js @@ -334,6 +334,7 @@ 'alt="' + userObj.username + '"', 'title="' + userObj.username + '"', 'data-uid="' + userObj.uid + '"', + 'loading="lazy"', ]; const styles = []; classNames = classNames || ''; From bcf85fcfba64ef0a91df9979331b3c6caa0d0f39 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 27 Oct 2021 12:14:04 -0400 Subject: [PATCH 300/412] fix(deps): update dependency nodebb-theme-persona to v11.2.19 (#9943) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index b158f0db09..c8e64170a2 100644 --- a/install/package.json +++ b/install/package.json @@ -93,7 +93,7 @@ "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", - "nodebb-theme-persona": "11.2.18", + "nodebb-theme-persona": "11.2.19", "nodebb-theme-slick": "1.4.14", "nodebb-theme-vanilla": "12.1.6", "nodebb-widget-essentials": "5.0.4", From bf20965f0bd68a46de4de4e3f274a6fbffa28073 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 27 Oct 2021 12:14:11 -0400 Subject: [PATCH 301/412] fix(deps): update dependency nodebb-theme-vanilla to v12.1.7 (#9944) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index c8e64170a2..61ef2eece4 100644 --- a/install/package.json +++ b/install/package.json @@ -95,7 +95,7 @@ "nodebb-theme-lavender": "5.2.1", "nodebb-theme-persona": "11.2.19", "nodebb-theme-slick": "1.4.14", - "nodebb-theme-vanilla": "12.1.6", + "nodebb-theme-vanilla": "12.1.7", "nodebb-widget-essentials": "5.0.4", "nodemailer": "^6.5.0", "nprogress": "0.2.0", From 28efcb59cbcd301424f58dffeb6e86a0f213095a Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Wed, 27 Oct 2021 12:35:10 -0400 Subject: [PATCH 302/412] chore: remove .opacity() mixin as it is supported cross-browser --- install/package.json | 4 ++-- public/less/generics.less | 2 +- public/less/mixins.less | 7 ------- src/meta/minifier.js | 2 +- 4 files changed, 4 insertions(+), 11 deletions(-) diff --git a/install/package.json b/install/package.json index 61ef2eece4..3dd20a53be 100644 --- a/install/package.json +++ b/install/package.json @@ -93,9 +93,9 @@ "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", - "nodebb-theme-persona": "11.2.19", + "nodebb-theme-persona": "11.2.20", "nodebb-theme-slick": "1.4.14", - "nodebb-theme-vanilla": "12.1.7", + "nodebb-theme-vanilla": "12.1.8", "nodebb-widget-essentials": "5.0.4", "nodemailer": "^6.5.0", "nprogress": "0.2.0", diff --git a/public/less/generics.less b/public/less/generics.less index 81ffd073ca..d7cd2b3ec3 100644 --- a/public/less/generics.less +++ b/public/less/generics.less @@ -39,7 +39,7 @@ &.disabled { background-color: #888!important; - .opacity(0.5); + opacity: 0.5; } } } diff --git a/public/less/mixins.less b/public/less/mixins.less index 57a54ea32b..04259bb089 100644 --- a/public/less/mixins.less +++ b/public/less/mixins.less @@ -32,13 +32,6 @@ } } -.opacity(@opacity: 1) { - -moz-opacity: @opacity; - opacity: @opacity; - -ms-filter: ~`"progid:DXImageTransform.Microsoft.Alpha(opacity=(" + "@{opacity}" * 100 + "))"`; - filter: ~`"alpha(opacity = (" + "@{opacity}" * 100 + "))"`; -} - .border-radius (@radius: 5px) { -webkit-border-radius: @radius; -moz-border-radius: @radius; diff --git a/src/meta/minifier.js b/src/meta/minifier.js index f388b3159e..cfb740755f 100644 --- a/src/meta/minifier.js +++ b/src/meta/minifier.js @@ -228,7 +228,7 @@ Minifier.js.minifyBatch = async function (scripts, fork) { actions.buildCSS = async function buildCSS(data) { const lessOutput = await less.render(data.source, { paths: data.paths, - javascriptEnabled: true, + javascriptEnabled: false, }); const postcssArgs = [autoprefixer]; From c248805165a06d82be171f442278710064945f9f Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 27 Oct 2021 16:47:58 +0000 Subject: [PATCH 303/412] chore: incrementing version number - v1.18.5 --- install/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index 61ef2eece4..a4b1e1148d 100644 --- a/install/package.json +++ b/install/package.json @@ -2,7 +2,7 @@ "name": "nodebb", "license": "GPL-3.0", "description": "NodeBB Forum", - "version": "1.18.4", + "version": "1.18.5", "homepage": "http://www.nodebb.org", "repository": { "type": "git", @@ -182,4 +182,4 @@ "url": "https://github.com/barisusakli" } ] -} +} \ No newline at end of file From 82eda23a9ef2ae2cf5f0cf75eda1800d6302e04e Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 27 Oct 2021 16:47:59 +0000 Subject: [PATCH 304/412] chore: update changelog for v1.18.5 --- CHANGELOG.md | 159 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 159 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a505089cd5..e339ad70ff 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,162 @@ +#### v1.18.5 (2021-10-27) + +##### Breaking Changes + +* disable javascript in custom less tab (719cfc0d) + +##### Chores + +* remove .opacity() mixin as it is supported cross-browser (28efcb59) +* up themes (463b2076) +* up persona (1438f409) +* incrementing version number - v1.18.4 (945c2b0b) +* update changelog for v1.18.4 (7cbcb521) +* **deps:** + * update dependency lint-staged to v11.2.6 (8d4bb8bb) + * update dependency lint-staged to v11.2.5 (0728a994) + * update dependency lint-staged to v11.2.4 (f76a7882) + * update dependency husky to v7.0.4 (2a3e13f3) + * update dependency mocha to v9.1.3 (4784f016) + * update dependency eslint-plugin-import to v2.25.2 (3c3f45d9) + * update dependency jsdom to v18 (4b8dcd4c) + * update dependency eslint-plugin-import to v2.25.1 (7c4aebbd) + * update dependency lint-staged to v11.2.3 (288b5456) + * update dependency lint-staged to v11.2.2 (f96c8c4d) + * update dependency @commitlint/cli to v13.2.1 (52c38a1d) + * update dependency lint-staged to v11.2.1 (022e8df0) + * update dependency eslint-config-nodebb to v0.0.3 (4b92df82) +* **i18n:** + * fallback strings for new resources: nodebb.admin-settings-email, nodebb.error (9b68dc37) + * fallback strings for new resources: nodebb.admin-dashboard (ff962b5d) + * fallback strings for new resources: nodebb.admin-dashboard, nodebb.admin-menu (abe59131) + * fallback strings for new resources: nodebb.admin-manage-digest, nodebb.admin-settings-user, nodebb.user (2bed40be) + +##### Documentation Changes + +* update verbiage re: login API route (94c4f87b) + +##### New Features + +* new ACP option `emailPrompt` ... which allows administrators to disable the client-side prompt to encourage users to enter or confirm their email addresses (80ea12c1) +* show popular searches (f4cf482a) +* new plugin hook to allow plugins to reject email address on new registration or email change (6b4f35c2) +* utilities login API route now starts an actual login session, if requested (806a1e50) +* add method name to deprecation message (b91ae088) +* quote tooltip (66fca4e0) +* additional quality options for jpeg uploads, added quality and compression settings for png uploads (d22b076b) +* #8053, biweekly digest option (f7967bdf) +* core submit button dropdown (605a5381) +* added failing i18n tests (35af7634) +* confirm before deleting all events (#9875) (56d05b4e) + +##### Bug Fixes + +* **deps:** + * update dependency nodebb-theme-vanilla to v12.1.7 (#9944) (bf20965f) + * update dependency nodebb-theme-persona to v11.2.19 (#9943) (bcf85fcf) + * update dependency nodebb-rewards-essentials to v0.2.0 (7c2ecb12) + * update dependency nodebb-theme-vanilla to v12.1.6 (49b8b983) + * update dependency nodebb-theme-persona to v11.2.18 (ed0adf2c) + * update dependency nodebb-theme-persona to v11.2.17 (78661079) + * update dependency postcss to v8.3.11 (a5f4e206) + * update dependency nodebb-theme-vanilla to v12.1.5 (d74a6bd3) + * update dependency sharp to v0.29.2 (8b8fe393) + * update dependency postcss to v8.3.10 (b18a24e9) + * update dependency nodebb-theme-persona to v11.2.15 (f3c8d7da) + * update dependency nodebb-theme-persona to v11.2.14 (#9919) (5e08e67b) + * update dependency socket.io-client to v4.3.2 (deba3e27) + * update dependency socket.io to v4.3.1 (e1554f61) + * update socket.io packages (ce5a0a21) + * update dependency nodebb-plugin-spam-be-gone to v0.7.10 (600a8720) + * update dependency nodebb-plugin-composer-default to v7.0.10 (b0128f85) + * update dependency nodebb-plugin-markdown to v8.14.4 (f8f35d7e) + * update dependency nodebb-plugin-composer-default to v7.0.9 (ed874662) + * update dependency nodebb-theme-persona to v11.2.13 (1dba75e9) + * update dependency ioredis to v4.28.0 (4ff5452d) + * update dependency nodebb-theme-persona to v11.2.12 (fe9f82f6) + * update dependency ioredis to v4.27.11 (6d2e0aa9) + * update dependency nodebb-plugin-mentions to v2.14.1 (820f8cdf) + * update dependency jquery-ui to v1.13.0 (b0eb2aed) +* remove loading="lazy", fixes inf. scroll loaded images (01572785) +* windows tests (25ebbd65) +* undefined query showing in searches (6cfaea06) +* don't repeat search if on same page (89f5e06b) +* api session revoke test (0926ae6e) +* crash (da64810a) +* add missing translation (eb075c73) +* move record to controller (ee8e0480) +* profile edit fields showing translated values (63572c23) +* #9934, fix translator test (8d316d18) +* token verify (04dab1d5) +* guard against prototype pollution (1783f918) +* translator path traversal (c8b2fc46) +* there is no alltime digest, fixes translation in test email (e62948f7) +* clicking outside postContainer should close tooltip (47df62e7) +* minification regression (998b9e79) +* tooltip (fec7ebed) +* biweekly digest #8053 (9cb4de50) +* restore plugin upgrade checking logic (44687394) +* fallbacks for new langauge key (ed4ebd22) +* #9917, show topics as unread for guests (4333d217) +* clarify site settings urls vs config.json url (#9912) (6436aa65) +* clarify SMTP enable toggle (#9911) (09f198fc) +* don't overwrite reloadRequired with false (9e0ce027) +* delete translations in admin/general folder (since general was removed and relocated elsewhere) (b460e590) +* pushed missing key to tx and pulled fallbacks (21b61082) +* adding missing language namespace "top" (0f9b0b78) +* extra debug log (bd893cda) +* have renovate add `dependencies` label to its PRs (eddb9868) +* no global bootbox (#9879) (227456fb) +* #9872 update app badge with notification count if applicable (3e69bcdf) +* better nomenclature (c1149d04) +* html attributes (#9877) (3acaac4c) +* escape thumbs, allow robots meta tag (4f9717fb) +* missing translations (#9876) (7935bd9e) + +##### Performance Improvements + +* dont fs.open if plugin doesnt have language namespace (#9893) (1feb111a) + +##### Refactors + +* wider value field (c428ba80) +* dont save partial searches (c7e078d4) +* use search api for topic search (64192731) +* slowdown quick search (19ee7174) +* typo (a5287906) +* add callback to loadNotifications (f02fba29) +* simplified utilities API > login rout (506c34a8) +* log error as well (1d62bd6d) +* catch errors from buildHeader in error handler :fire: (73a9ca09) +* add missing helpers.tryRoute (d4da9840) +* shorter middleware (ee0282f5) +* meta/minifier use async/await (b2429ef0) +* remove unused var (90b81262) +* catch errors from digest (8e319a9b) +* less.render returns promise (14bc83a8) +* less.render already returns promise (6da32392) +* prompt.get already returns promise (c70eaa0a) +* no need for async/callbacks (057d1d58) +* no more :cow: (38756a0c) +* allow array of uids for blocks.is/list (a9bc6a09) +* show full url on error log (8e6bd7e9) +* var to const and let (#9885) (b0a24d6d) +* remove unused code (997fb2b3) +* remove unused colorpicker (543d8521) + +##### Reverts + +* lazy load (3d1cf168) + +##### Tests + +* fix broken openapi3 schema (7ef5214e) +* restore commented-out i18n test (fa1afbcf) +* moved topic event and topic thumb tests to subfolder for better organisation (154ffea0) +* remove escape (6c25b9db) +* possible fix to timeout (63109c07) +* increase timeout (8654a996) + #### v1.18.4 (2021-10-06) ##### Chores From 1e418f5b5e763fb725fdfcc9368a5f42c3b10732 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 27 Oct 2021 16:47:58 +0000 Subject: [PATCH 305/412] chore: incrementing version number - v1.18.5 (cherry picked from commit c248805165a06d82be171f442278710064945f9f) Signed-off-by: Misty (Bot) --- install/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index 3dd20a53be..cb89650f40 100644 --- a/install/package.json +++ b/install/package.json @@ -2,7 +2,7 @@ "name": "nodebb", "license": "GPL-3.0", "description": "NodeBB Forum", - "version": "1.18.4", + "version": "1.18.5", "homepage": "http://www.nodebb.org", "repository": { "type": "git", @@ -182,4 +182,4 @@ "url": "https://github.com/barisusakli" } ] -} +} \ No newline at end of file From 8f08d9cac03abeb9958cda51e5df55593d4bedc6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 27 Oct 2021 14:21:36 -0400 Subject: [PATCH 306/412] fix: handle undefined data.query --- src/search.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/search.js b/src/search.js index e336031e45..0a0d1f459c 100644 --- a/src/search.js +++ b/src/search.js @@ -58,7 +58,7 @@ async function searchInContent(data) { } let pids = []; let tids = []; - const inTopic = data.query.match(/^in:topic-([\d]+) /); + const inTopic = String(data.query || '').match(/^in:topic-([\d]+) /); if (inTopic) { const tid = inTopic[1]; const cleanedTerm = data.query.replace(inTopic[0], ''); From ebe7f11d0b410d03bb2367945ec04f0924f453c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 27 Oct 2021 14:21:36 -0400 Subject: [PATCH 307/412] merge --- src/search.js | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/src/search.js b/src/search.js index 99fae633e8..0a0d1f459c 100644 --- a/src/search.js +++ b/src/search.js @@ -56,10 +56,19 @@ async function searchInContent(data) { } return []; } - const [pids, tids] = await Promise.all([ - doSearch('post', ['posts', 'titlesposts']), - doSearch('topic', ['titles', 'titlesposts']), - ]); + let pids = []; + let tids = []; + const inTopic = String(data.query || '').match(/^in:topic-([\d]+) /); + if (inTopic) { + const tid = inTopic[1]; + const cleanedTerm = data.query.replace(inTopic[0], ''); + pids = await topics.search(tid, cleanedTerm); + } else { + [pids, tids] = await Promise.all([ + doSearch('post', ['posts', 'titlesposts']), + doSearch('topic', ['titles', 'titlesposts']), + ]); + } if (data.returnIds) { return { pids: pids, tids: tids }; From bda5d1442574226f2fd4f021ef3b431a4875c9fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 27 Oct 2021 14:40:42 -0400 Subject: [PATCH 308/412] test: empty query params for search --- test/search.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/test/search.js b/test/search.js index 909a1b7f2f..ee28dd3956 100644 --- a/test/search.js +++ b/test/search.js @@ -273,4 +273,20 @@ describe('Search', () => { }); }); }); + + it('should not crash without a search term', (done) => { + const qs = '/api/search'; + privileges.global.give(['groups:search:content'], 'guests', (err) => { + assert.ifError(err); + request({ + url: nconf.get('url') + qs, + json: true, + }, (err, response, body) => { + assert.ifError(err); + assert(body); + assert.strictEqual(response.statusCode, 200); + privileges.global.rescind(['groups:search:content'], 'guests', done); + }); + }); + }); }); From 4ffbbae8788b57c74da15d4c0a271bf594be2610 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Thu, 28 Oct 2021 09:07:10 +0000 Subject: [PATCH 309/412] Latest translations and fallbacks --- public/language/sl/admin/advanced/events.json | 2 +- .../sl/admin/appearance/customise.json | 2 +- public/language/sl/admin/dashboard.json | 12 +++---- public/language/sl/admin/manage/users.json | 12 +++---- public/language/sl/admin/menu.json | 34 +++++++++---------- public/language/tr/admin/advanced/events.json | 2 +- public/language/tr/admin/dashboard.json | 10 +++--- .../language/tr/admin/manage/categories.json | 2 +- public/language/tr/admin/manage/digest.json | 2 +- .../language/tr/admin/manage/privileges.json | 16 ++++----- public/language/tr/admin/manage/uploads.json | 4 +-- public/language/tr/admin/manage/users.json | 4 +-- public/language/tr/admin/menu.json | 2 +- public/language/tr/admin/settings/email.json | 14 ++++---- .../language/tr/admin/settings/general.json | 22 ++++++------ .../tr/admin/settings/notifications.json | 2 +- public/language/tr/admin/settings/post.json | 8 ++--- .../tr/admin/settings/reputation.json | 2 +- public/language/tr/admin/settings/user.json | 2 +- public/language/tr/email.json | 6 ++-- public/language/tr/error.json | 20 +++++------ public/language/tr/global.json | 2 +- public/language/tr/modules.json | 2 +- public/language/tr/register.json | 6 ++-- public/language/tr/topic.json | 14 ++++---- public/language/tr/user.json | 10 +++--- 26 files changed, 107 insertions(+), 107 deletions(-) diff --git a/public/language/sl/admin/advanced/events.json b/public/language/sl/admin/advanced/events.json index 1b5a03dc18..a06766728e 100644 --- a/public/language/sl/admin/advanced/events.json +++ b/public/language/sl/admin/advanced/events.json @@ -3,7 +3,7 @@ "no-events": "Ni dogodkov", "control-panel": "Nadzorna plošča za dogodke", "delete-events": "Izbriši dogodke", - "confirm-delete-all-events": "Are you sure you want to delete all logged events?", + "confirm-delete-all-events": "Ali ste prepričani, da želite izbrisati vse zabeležene dogodke?", "filters": "Filtri", "filters-apply": "Uveljavi filtre", "filter-type": "Tip dogodka", diff --git a/public/language/sl/admin/appearance/customise.json b/public/language/sl/admin/appearance/customise.json index cea68f5b8a..744b60dc2e 100644 --- a/public/language/sl/admin/appearance/customise.json +++ b/public/language/sl/admin/appearance/customise.json @@ -11,6 +11,6 @@ "custom-header.description": "Tukaj vnesite HTML po meri (npr. meta oznake itd.), ki bo dodan v & lt; head & gt; razdelek oznak vašega foruma. Oznake skript so dovoljene, vendar niso priporočljive, saj je na voljo zavihek Javascript po meri.", "custom-header.enable": "Omogoči glavo po meri", - "custom-css.livereload": "Enable Live Reload", + "custom-css.livereload": "Omogoči ponovno nalaganje v živo", "custom-css.livereload.description": "Omogočite to, da se vse seje na vsaki napravi v vašem računu osvežijo, ko kliknete shrani" } \ No newline at end of file diff --git a/public/language/sl/admin/dashboard.json b/public/language/sl/admin/dashboard.json index 9f7b21b93a..7b8d329e5c 100644 --- a/public/language/sl/admin/dashboard.json +++ b/public/language/sl/admin/dashboard.json @@ -56,19 +56,19 @@ "active-users.total": "Skupaj", "active-users.connections": "Povezave", - "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest-registered-users": "Gostujoči napram registriranim uporabnikom", + "guest": "Gost", "registered": "Registrirani", "user-presence": "Prisotnost uporabnikov", - "on-categories": "On categories list", + "on-categories": "Na seznam kategorij", "reading-posts": "Branje objav", "browsing-topics": "Brskanje po temah", "recent": "Nedavno", "unread": "Neprebrano", "high-presence-topics": "Teme z visoko prisotnostjo", - "popular-searches": "Popular Searches", + "popular-searches": "Priljubljena iskanja", "graphs.page-views": "Ogledov strani", "graphs.page-views-registered": "Ogledov strani-registrirani", @@ -76,14 +76,14 @@ "graphs.page-views-bot": "Ogledov strani-robot", "graphs.unique-visitors": "Edinstveni obiskovalci", "graphs.registered-users": "Registrirani uporabniki", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "Gostujoči uporabniki", "last-restarted-by": "Nazadnje ponovno zagnal(a)", "no-users-browsing": "Ne brska noben uporabnik", "back-to-dashboard": "Nazaj na nadzorno ploščo", "details.no-users": "V izbranem časovnem okviru se ni pridružil noben uporabnik", "details.no-topics": "V izbranem časovnem okviru ni bila objavljena nobena tema", - "details.no-searches": "No searches have been made yet", + "details.no-searches": "Iskanja še niso bila izvedena", "details.no-logins": "V izbranem časovnem okviru ni bila zabeležena nobena prijava", "details.logins-static": "NodeBB shranjuje samo podatke o sejah za %1 dni, zato bo ta spodnja tabela prikazala samo zadnje aktivne seje", "details.logins-login-time": "Čas prijave" diff --git a/public/language/sl/admin/manage/users.json b/public/language/sl/admin/manage/users.json index 4f9ca41006..8fbd1bc68f 100644 --- a/public/language/sl/admin/manage/users.json +++ b/public/language/sl/admin/manage/users.json @@ -1,8 +1,8 @@ { "users": "Uporabniki", "edit": "Dejanja", - "make-admin": "Make Admin", - "remove-admin": "Remove Admin", + "make-admin": "Nastavi kot skrbnika", + "remove-admin": "Odstrani kot skrbnika", "validate-email": "Potrdite e-poštni naslov", "send-validation-email": "Pošljite potrditveno e-sporočilo", "password-reset-email": "Pošljite e-poštno sporočilo za ponastavitev gesla", @@ -40,14 +40,14 @@ "search.ip-placeholder": "Za iskanje vnesite IP naslov", "search.not-found": "Uporabnika ni bilo mogoče najti!", - "inactive.3-months": "3 months", - "inactive.6-months": "6 months", - "inactive.12-months": "12 months", + "inactive.3-months": "3 mes.", + "inactive.6-months": "6 mes.", + "inactive.12-months": "12 mes.", "users.uid": "uid", "users.username": "uporabniško ime", "users.email": "e-poštni naslov", - "users.no-email": "(no email)", + "users.no-email": "(ni e-poštnega naslova)", "users.ip": "IP", "users.postcount": "postcount", "users.reputation": "ugled", diff --git a/public/language/sl/admin/menu.json b/public/language/sl/admin/menu.json index 0484b96aee..14b3e8c210 100644 --- a/public/language/sl/admin/menu.json +++ b/public/language/sl/admin/menu.json @@ -1,10 +1,10 @@ { "section-dashboard": "Dashboards", - "dashboard/overview": "Overview", + "dashboard/overview": "Pregled", "dashboard/logins": "Prijave", "dashboard/users": "Uporabniki", "dashboard/topics": "Teme", - "dashboard/searches": "Searches", + "dashboard/searches": "Iskanja", "section-general": "Splošno", "section-manage": "Upravljaj", @@ -12,13 +12,13 @@ "manage/privileges": "Privileges", "manage/tags": "Oznake", "manage/users": "Uporabniki", - "manage/admins-mods": "Admins & Mods", + "manage/admins-mods": "Skrbniki in moderatorji", "manage/registration": "Čakalna vrsta registracij", "manage/post-queue": "Čakalna vrsta objav", "manage/groups": "Skupine", "manage/ip-blacklist": "IP črna lista", - "manage/uploads": "Uploads", - "manage/digest": "Digests", + "manage/uploads": "Nalaganja", + "manage/digest": "Povzetki", "section-settings": "Nastavitve", "settings/general": "Splošno", @@ -29,16 +29,16 @@ "settings/user": "Uporabniki", "settings/group": "Skupine", "settings/guest": "Gostje", - "settings/uploads": "Uploads", + "settings/uploads": "Nalaganja", "settings/languages": "Jeziki", "settings/post": "Objave", "settings/chat": "Klepeti", "settings/pagination": "Številčenje strani", "settings/tags": "Oznake", "settings/notifications": "Obvestila", - "settings/api": "API Access", + "settings/api": "API dostop", "settings/sounds": "Zvoki", - "settings/social": "Social", + "settings/social": "Družbeno", "settings/cookies": "Piškotki", "settings/web-crawler": "Web Crawler", "settings/sockets": "Vtičnice", @@ -48,12 +48,12 @@ "section-appearance": "Videz", "appearance/themes": "Teme", - "appearance/skins": "Skins", - "appearance/customise": "Custom Content (HTML/JS/CSS)", + "appearance/skins": "Preobleke", + "appearance/customise": "Vsebina po meri (HTML/JS/CSS)", "section-extend": "Extend", "extend/plugins": "Vtičniki", - "extend/widgets": "Widgets", + "extend/widgets": "Pripomočki", "extend/rewards": "Nagrade", "section-social-auth": "Social Authentication", @@ -67,7 +67,7 @@ "advanced/hooks": "Hooks", "advanced/logs": "Prijave", "advanced/errors": "Napake", - "advanced/cache": "Cache", + "advanced/cache": "Predpomnilnik", "development/logger": "Logger", "development/info": "Info", @@ -78,12 +78,12 @@ "search.placeholder": "Press "/" to search for settings", "search.no-results": "Ni rezultatov...", - "search.search-forum": "Search the forum for ", - "search.keep-typing": "Type more to see results...", - "search.start-typing": "Start typing to see results...", + "search.search-forum": "Na forumu poišči ", + "search.keep-typing": "Vnesite več, da vidite rezultate...", + "search.start-typing": "Začnite tipkati, da vidite rezultate...", - "connection-lost": "Connection to %1 has been lost, attempting to reconnect...", + "connection-lost": "Povezava z %1 je bila izgubljena, poskus ponovne povezave...", - "alerts.version": "Running NodeBB v%1", + "alerts.version": "Teče NodeBB v%1", "alerts.upgrade": "Nadgradi na v%1" } \ No newline at end of file diff --git a/public/language/tr/admin/advanced/events.json b/public/language/tr/admin/advanced/events.json index aebc5bd0da..14bdd8788c 100644 --- a/public/language/tr/admin/advanced/events.json +++ b/public/language/tr/admin/advanced/events.json @@ -3,7 +3,7 @@ "no-events": "Aktivite yok", "control-panel": "Aktivite Kontrol Paneli", "delete-events": "Aktiviteyi Sil", - "confirm-delete-all-events": "Are you sure you want to delete all logged events?", + "confirm-delete-all-events": "Kaydedilen tüm etkinlikleri silmek istediğinizden emin misiniz?", "filters": "Filtreler", "filters-apply": "Filtreleri Uygula", "filter-type": "Aktivite türü", diff --git a/public/language/tr/admin/dashboard.json b/public/language/tr/admin/dashboard.json index 132f58a29a..f7bdad37b3 100644 --- a/public/language/tr/admin/dashboard.json +++ b/public/language/tr/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Genel Toplam", "active-users.connections": "Bağlantılar", - "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest-registered-users": "Misafir ve Kayıtlı Kullanıcılar", + "guest": "Misafir", "registered": "Kayıtlı", "user-presence": "Kullanıcı Durumları", @@ -68,7 +68,7 @@ "unread": "Okunmamış Konular Sayfasında", "high-presence-topics": "Öne Çıkan Başlıklar", - "popular-searches": "Popular Searches", + "popular-searches": "Popüler Aramalar", "graphs.page-views": "Sayfa Gösterimi", "graphs.page-views-registered": "Kayıtlı Kullanıcıların Sayfa Gösterimi", @@ -76,14 +76,14 @@ "graphs.page-views-bot": "Bot Sayfa Gösterimi", "graphs.unique-visitors": "Benzersiz Ziyaretçiler", "graphs.registered-users": "Kayıtlı Kullanıcılar", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "Misafir Kullanıcılar", "last-restarted-by": "Son yeniden başlatma bilgisi", "no-users-browsing": "İnceleyen kullanıcı yok", "back-to-dashboard": "Yönetim Paneline geri dön", "details.no-users": "Seçilen zaman aralığında herhangi bir kullanıcı üye olmadı.", "details.no-topics": "Seçilen zaman aralığında herhangi bir başlık oluşturulmadı. ", - "details.no-searches": "No searches have been made yet", + "details.no-searches": "Henüz arama yapılmadı", "details.no-logins": "Seçilen zaman aralığında herhangi bir giriş yapılmadı.", "details.logins-static": "NodeBB oturum kayıtlarını sadece %1 gün tutar, o nedenle aşağıdaki tablo sadece en yakın aktif oturumları listeler", "details.logins-login-time": "Giriş zamanı" diff --git a/public/language/tr/admin/manage/categories.json b/public/language/tr/admin/manage/categories.json index 5d09d269e6..c15eb8d545 100644 --- a/public/language/tr/admin/manage/categories.json +++ b/public/language/tr/admin/manage/categories.json @@ -33,7 +33,7 @@ "analytics": "Analiz", "view-category": "Kategori Görüntüle", "set-order": "Bir sıra ayarla", - "set-order-help": "Setting the order of the category will move this category to that order and update the order of other categories as necessary. Minimum order is 1 which puts the category at the top.", + "set-order-help": "Kategorinin sırasını ayarlamak, bu kategoriyi o sıraya taşıyacak ve diğer kategorilerin sırasını güncelleyecektir. Kategoriyi en üste taşımak için 1 girin.", "select-category": "Kategori Seç", "set-parent-category": "Ana Kategori Ayarla", diff --git a/public/language/tr/admin/manage/digest.json b/public/language/tr/admin/manage/digest.json index 1548169764..5caee118ff 100644 --- a/public/language/tr/admin/manage/digest.json +++ b/public/language/tr/admin/manage/digest.json @@ -13,7 +13,7 @@ "resent-single": "El ile özet gönderimi tamamlandı", "resent-day": "Günlük özet yeniden gönderildi", "resent-week": "Haftalık özet yeniden gönderildi", - "resent-biweek": "Bi-Weekly digest resent", + "resent-biweek": "İki Haftalık özeti yeniden gönder", "resent-month": "Aylık özet yeniden gönderildi", "null": "Hiçbir zaman", "manual-run": "El ile özet gönderimi:", diff --git a/public/language/tr/admin/manage/privileges.json b/public/language/tr/admin/manage/privileges.json index a915eb8d45..e641167ad8 100644 --- a/public/language/tr/admin/manage/privileges.json +++ b/public/language/tr/admin/manage/privileges.json @@ -25,7 +25,7 @@ "access-topics": "Başlıklara Eriş", "create-topics": "Başlık Oluştur", "reply-to-topics": "Başlığı Cevapla", - "schedule-topics": "Schedule Topics", + "schedule-topics": "Konuları Planla", "tag-topics": "Başlığı etiketle", "edit-posts": "İletiyi düzenle", "view-edit-history": "Düzenleme Geçmişini Görüntüle", @@ -51,13 +51,13 @@ "alert.saved": "Ayrıcalık değişiklikleri kaydedildi ve uygulandı", "alert.confirm-discard": "Ayrıcalık değişikliklerini iptal etmek istediğinize emin misiniz?", "alert.discarded": "Ayrıcalık değişiklikleri iptal edildi", - "alert.confirm-copyToAll": "Are you sure you wish to apply this set of %1 to all categories?", - "alert.confirm-copyToAllGroup": "Are you sure you wish to apply this group's set of %1 to all categories?", - "alert.confirm-copyToChildren": "Are you sure you wish to apply this set of %1 to all descendant (child) categories?", - "alert.confirm-copyToChildrenGroup": "Are you sure you wish to apply this group's set of %1 to all descendant (child) categories?", + "alert.confirm-copyToAll": "Bu %1 kategorisini tüm kategorilere uygulamak istediğinizden emin misiniz? ", + "alert.confirm-copyToAllGroup": "Bu grubun %1 kümesini tüm kategorilere uygulamak istediğinizden emin misiniz?", + "alert.confirm-copyToChildren": "Bu %1 kümesini tüm alt (alt) kategorilere uygulamak istediğinizden emin misiniz?", + "alert.confirm-copyToChildrenGroup": "Bu grubun %1 kümesini tüm alt (alt) kategorilere uygulamak istediğinizden emin misiniz?", "alert.no-undo": "Bu işlem geri alınamaz.", "alert.admin-warning": "Yöneticiler dolaylı olarak tüm ayrıcalıklara sahiptirler", - "alert.copyPrivilegesFrom-title": "Select a category to copy from", - "alert.copyPrivilegesFrom-warning": "This will copy %1 from the selected category.", - "alert.copyPrivilegesFromGroup-warning": "This will copy this group's set of %1 from the selected category." + "alert.copyPrivilegesFrom-title": "Kopyalamak için bir kategori seçin", + "alert.copyPrivilegesFrom-warning": "Seçilen kategoriden %1 kopyalayacaktır.", + "alert.copyPrivilegesFromGroup-warning": "Bu, seçilen kategoriden bu grubun %1 kümesini kopyalayacaktır." } \ No newline at end of file diff --git a/public/language/tr/admin/manage/uploads.json b/public/language/tr/admin/manage/uploads.json index 60fbb950ba..c3cd6a4574 100644 --- a/public/language/tr/admin/manage/uploads.json +++ b/public/language/tr/admin/manage/uploads.json @@ -6,6 +6,6 @@ "size/filecount": "Boyut / Dosya sayısı", "confirm-delete": "Bu dosyayı silmek istediğinden emin misin?", "filecount": "%1 dosya", - "new-folder": "New Folder", - "name-new-folder": "Enter a name for new the folder" + "new-folder": "Yeni Dosya", + "name-new-folder": "Yeni klasör için bir ad girin" } \ No newline at end of file diff --git a/public/language/tr/admin/manage/users.json b/public/language/tr/admin/manage/users.json index ebe7d2c28b..aa8b784cb6 100644 --- a/public/language/tr/admin/manage/users.json +++ b/public/language/tr/admin/manage/users.json @@ -1,6 +1,6 @@ { "users": "Kullanıcılar", - "edit": "Actions", + "edit": "Hareketler", "make-admin": "Yönetici Yap", "remove-admin": "Yöneticiliği Sil", "validate-email": "E-postayı Doğrula", @@ -47,7 +47,7 @@ "users.uid": "benzersiz id", "users.username": "kullanıcı adı", "users.email": "e-posta", - "users.no-email": "(no email)", + "users.no-email": "(e-mail yok)", "users.ip": "IP", "users.postcount": "ileti sayısı", "users.reputation": "itibar", diff --git a/public/language/tr/admin/menu.json b/public/language/tr/admin/menu.json index 0d5e14bc14..821acc2ed1 100644 --- a/public/language/tr/admin/menu.json +++ b/public/language/tr/admin/menu.json @@ -4,7 +4,7 @@ "dashboard/logins": "Girişler", "dashboard/users": "Kullanıcılar", "dashboard/topics": "Başlıklar", - "dashboard/searches": "Searches", + "dashboard/searches": "Aramalar", "section-general": "Genel", "section-manage": "Yönet", diff --git a/public/language/tr/admin/settings/email.json b/public/language/tr/admin/settings/email.json index 3d77ac0d53..0dffd74edf 100644 --- a/public/language/tr/admin/settings/email.json +++ b/public/language/tr/admin/settings/email.json @@ -6,7 +6,7 @@ "from-help": "The from name to display in the email.", "smtp-transport": "SMTP Transport", - "smtp-transport.enabled": "Enable SMTP Transport", + "smtp-transport.enabled": "SMTP Aktarımını Etkinleştir", "smtp-transport-help": "You can select from a list of well-known services or enter a custom one.", "smtp-transport.service": "Select a service", "smtp-transport.service-custom": "Özel Servis", @@ -37,10 +37,10 @@ "subscriptions.hour": "Digest Hour", "subscriptions.hour-help": "Please enter a number representing the hour to send scheduled email digests (e.g. 0 for midnight, 17 for 5:00pm). Keep in mind that this is the hour according to the server itself, and may not exactly match your system clock.
    The approximate server time is:
    The next daily digest is scheduled to be sent ", "notifications.remove-images": "Görselleri e-posta bildirimlerinden kaldır", - "require-email-address": "Require new users to specify an email address", - "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", - "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", - "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", - "prompt": "Prompt users to enter or confirm their emails", - "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." + "require-email-address": "Yeni kullanıcıların bir e-posta adresi belirtmesini gerektir", + "require-email-address-warning": "Varsayılan olarak kullanıcıların bir e-posta adresi girmesi devre dışıdır. Bu seçeneğin etkinleştirilmesi, kayıt işlemine devam etmek için bir e-posta adresi girmeleri gerektiği anlamına gelir. Elbette bu kullanıcının gerçek bir e-posta adresi veya sahip olduğu bir adresi girmelerini sağlamaz.", + "include-unverified-emails": "E-postalarını onaylamayan alıcılara onay e-postası gönderin", + "include-unverified-warning": "Varsayılan olarak, hesaplarıyla ilişkili e-postaları olan kullanıcılar (Sosyal Login) zaten doğrulanmıştır, ancak durumun böyle olmadığı durumlar vardır (ör. Riski size ait olmak üzere bu ayarı etkinleştirin – doğrulanmamış adreslere e-posta göndermek, bölgesel istenmeyen posta önleme yasalarının ihlali olabilir.", + "prompt": "Kullanıcılardan e-postalarını girmelerini veya onaylamalarını isteyin", + "prompt-help": "Bir kullanıcının e-posta seti yoksa veya e-postası onaylanmadıysa ekranda bir uyarı gösterilir." } diff --git a/public/language/tr/admin/settings/general.json b/public/language/tr/admin/settings/general.json index 2d58a0e610..6bf2e17cdf 100644 --- a/public/language/tr/admin/settings/general.json +++ b/public/language/tr/admin/settings/general.json @@ -3,9 +3,9 @@ "title": "Site Başlığı", "title.short": "Başlık Kısaltması", "title.short-placeholder": "Eğer başlık kısaltması girilmediyse \"Site Başlığı\" kullanılacak", - "title.url": "Title Link URL", + "title.url": "Başlık Bağlantı URL'si", "title.url-placeholder": "Site başlığının URL adresi", - "title.url-help": "When the title is clicked, send users to this address. If left blank, user will be sent to the forum index.
    Note: This is not the external URL used in emails, etc. That is set by the url property in config.json", + "title.url-help": "Başlık tıklandığında kullanıcıları bu adrese gönderin. Boş bırakılırsa, kullanıcı forum dizinine gönderilecektir. Not: Bu, e-postalarda vb. kullanılan harici URL değildir. Bu, config.json'daki url özelliği tarafından belirlenir.", "title.name": "Topluluk İsmi", "title.show-in-header": "Site Konusunu Başlık'ta Göster", "browser-title": "Tarayıcı Başlığı", @@ -20,9 +20,9 @@ "logo.image": "Görsel", "logo.image-placeholder": "Forum başlığında görüntülenecek bir logo yolu", "logo.upload": "Yükle", - "logo.url": "Logo Link URL", + "logo.url": "Logonun Linki", "logo.url-placeholder": "Site Logo URL'si", - "logo.url-help": "When the logo is clicked, send users to this address. If left blank, user will be sent to the forum index.
    Note: This is not the external URL used in emails, etc. That is set by the url property in config.json", + "logo.url-help": "Logoya tıklandığında kullanıcıları bu adrese gönderin. Boş bırakılırsa, kullanıcı forum dizinine gönderilecektir. Not: Bu, e-postalarda vb. kullanılan harici URL değildir. Bu, config.json'daki url özelliği tarafından belirlenir.", "logo.alt-text": "Alt Yazı", "log.alt-text-placeholder": "Erişilebilirlik için alternatif metin", "favicon": "Favicon", @@ -35,16 +35,16 @@ "maskable-icon.help": "Önerilen boyut ve format: 512x512, PNG formatı. If no maskable icon is specified, NodeBB will fall back to the Touch Icon.", "outgoing-links": "Harici Bağlantılar", "outgoing-links.warning-page": "Dışarı giden bağlantılar için uyarı sayfası kullan", - "search": "Search", - "search-default-in": "Search In", - "search-default-in-quick": "Quick Search In", - "search-default-sort-by": "Sort by", + "search": "Arama", + "search-default-in": "Araştır", + "search-default-in-quick": "Hızlı Arama", + "search-default-sort-by": "Göre sırala", "outgoing-links.whitelist": "Uyarı sayfasını atlamak için beyaz listeye eklenecek alan-adları", "site-colors": "Site Renk Metaverisi", "theme-color": "Tema rengi", "background-color": "Arkaplan rengi", "background-color-help": "Site PWA olarak kurulduğunda ekran arkaplanı olarak kullanılacak renk", - "undo-timeout": "Undo Timeout", - "undo-timeout-help": "Some operations such as moving topics will allow for the moderator to undo their action within a certain timeframe. Set to 0 to disable undo completely.", - "topic-tools": "Topic Tools" + "undo-timeout": "Zaman Aşımını Geri Al", + "undo-timeout-help": "Konu taşıma gibi bazı işlemler, moderatörün belirli bir zaman dilimi içinde eylemlerini geri almasına olanak tanır. Tamamen geri almayı devre dışı bırakmak için 0'a ayarlayın.", + "topic-tools": "Konu Araçları" } diff --git a/public/language/tr/admin/settings/notifications.json b/public/language/tr/admin/settings/notifications.json index a4b20aa0d8..bf9502ff3d 100644 --- a/public/language/tr/admin/settings/notifications.json +++ b/public/language/tr/admin/settings/notifications.json @@ -3,5 +3,5 @@ "welcome-notification": "Hoş Geldin Bildirimi", "welcome-notification-link": "Hoş Geldin Bildirimi Bağlantısı", "welcome-notification-uid": "Kullanıcı Hoş Geldiniz Bildirimi (UID)", - "post-queue-notification-uid": "Post Queue User (UID)" + "post-queue-notification-uid": "İletisi kuyruğa alınan kullanıcı (UID)" } \ No newline at end of file diff --git a/public/language/tr/admin/settings/post.json b/public/language/tr/admin/settings/post.json index dee17e7dc2..8eb9aba208 100644 --- a/public/language/tr/admin/settings/post.json +++ b/public/language/tr/admin/settings/post.json @@ -51,14 +51,14 @@ "signature.no-links": "İmzalarda linkleri devre dışı bırak", "signature.no-images": "İmzalarda resimleri devre dışı bırak", "signature.max-length": "Maksimum İmza Uzunluğu", - "composer": "Yazar Ayarları", + "composer": "Editör Ayarları", "composer-help": "Aşağıdaki ayarlar, yeni konular oluşturduklarında veya mevcut konulara cevap verdiklerinde kullanıcıların \n\t\t\t\tyazı alanının işlevselliğini ve / veya görünümünü yönetmelerini sağlar.", "composer.show-help": "\"Yardım\" sekmesini göster", "composer.enable-plugin-help": "Eklentilerin yardım sekmesine içerik eklemesine izin ver", "composer.custom-help": "Özel Yardım Metni", - "backlinks": "Backlinks", - "backlinks.enabled": "Enable topic backlinks", - "backlinks.help": "If a post references another topic, a link back to the post will be inserted into the referenced topic at that point in time.", + "backlinks": "Geri bağlantılar", + "backlinks.enabled": "Konu geri bağlantılarını etkinleştir", + "backlinks.help": "Bir gönderi başka bir konuya atıfta bulunuyorsa, o anda referans verilen konuya gönderiye geri bir bağlantı eklenir.", "ip-tracking": "IP İzleme", "ip-tracking.each-post": "Her ileti için IP Adresini takip et", "enable-post-history": "Gönderi Geçmişini Etkinleştir" diff --git a/public/language/tr/admin/settings/reputation.json b/public/language/tr/admin/settings/reputation.json index 0109e0de78..cf5c2af702 100644 --- a/public/language/tr/admin/settings/reputation.json +++ b/public/language/tr/admin/settings/reputation.json @@ -17,6 +17,6 @@ "flags": "Şikayet Ayarları", "flags.limit-per-target": "Maksimum şikayet edilme sayısı", "flags.limit-per-target-placeholder": "Varsayılan: 0", - "flags.limit-per-target-help": "When a post or user is flagged multiple times, each additional flag is considered a "report" and added to the original flag. Set this option to a number other than zero to limit the number of reports an item can receive.", + "flags.limit-per-target-help": "Bir gönderi veya kullanıcı birden çok kez işaretlendiğinde, her ek işaret bir \"rapor\" olarak kabul edilir ve orijinal bayrağa eklenir. Bir öğenin alabileceği rapor sayısını sınırlamak için bu seçeneği sıfırdan farklı bir sayıya ayarlayın.", "flags.auto-resolve-on-ban": "Bir kullanıcı forumdan yasaklandığında otomatik olarak şikayetlerini çözülmüş say" } \ No newline at end of file diff --git a/public/language/tr/admin/settings/user.json b/public/language/tr/admin/settings/user.json index 99f120b5d8..ed09675de3 100644 --- a/public/language/tr/admin/settings/user.json +++ b/public/language/tr/admin/settings/user.json @@ -71,7 +71,7 @@ "digest-freq.off": "Kapalı", "digest-freq.daily": "Günlük", "digest-freq.weekly": "Haftalık", - "digest-freq.biweekly": "Bi-Weekly", + "digest-freq.biweekly": "İki haftada bir", "digest-freq.monthly": "Aylık", "email-chat-notifs": "Çevrimiçi değilken gelen mesajları e-posta olarak gönder", "email-post-notif": "Abone olduğum konulara cevap gelince bana e-posta gönder", diff --git a/public/language/tr/email.json b/public/language/tr/email.json index d91faa6217..e7d587826a 100644 --- a/public/language/tr/email.json +++ b/public/language/tr/email.json @@ -6,9 +6,9 @@ "greeting_no_name": "Merhaba", "greeting_with_name": "Merhaba %1", "email.verify-your-email.subject": "Lütfen e-posta adresinizi doğrulayın", - "email.verify.text1": "You've requested that we change or confirm your email address", - "email.verify.text2": "For security purposes, we only change or confirm the email address on file once its ownership has been confirmed via email. If you did not request this, no action is required on your part.", - "email.verify.text3": "Once you confirm this email address, we will replace your current email address with this one (%1).", + "email.verify.text1": "E-posta adresinizi değiştirmemizi veya onaylamamızı istediniz", + "email.verify.text2": "Güvenlik amacıyla, kayıtlı e-posta adresini yalnızca sahipliği e-posta yoluyla onaylandıktan sonra değiştirir veya onaylarız. Bunu talep etmediyseniz, herhangi bir işlem yapmanız gerekmez.", + "email.verify.text3": "Bu e-posta adresini onayladığınızda, mevcut e-posta adresinizi bununla (%1) değiştireceğiz.", "welcome.text1": "Kaydolduğunuz için teşekkürler!", "welcome.text2": "Hesabınızı aktif hale getirmek için, kaydolduğunuz e-posta adresinin size ait olduğunu onaylamamız gerekiyor.", "welcome.text3": "Yönetici kayıt olma isteğinizi kabul etti. Kullanıcı adı/şifre ile giriş yapabilirsiniz.", diff --git a/public/language/tr/error.json b/public/language/tr/error.json index 28e7e76b52..18c718f5b1 100644 --- a/public/language/tr/error.json +++ b/public/language/tr/error.json @@ -32,10 +32,10 @@ "email-taken": "E-posta Alınmış", "email-nochange": "Girdiğiniz e-posta var olan e-posta ile aynı", "email-invited": "E-posta halihazırda davet edilmiş", - "email-not-confirmed": "Posting in some categories or topics is enabled once your email is confirmed, please click here to send a confirmation email.", + "email-not-confirmed": "E-postanız onaylandıktan sonra bazı kategorilerde veya konularda gönderiler etkinleştirilir, lütfen bir onay e-postası göndermek için burayı tıklayın.", "email-not-confirmed-chat": "E-postanız onaylanana kadar sohbet edemezsiniz, onaylamak için lütfen buraya tıklayın.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", + "email-not-confirmed-email-sent": "E-postanız henüz onaylanmadı, lütfen onay e-postası için gelen kutunuzu kontrol edin. E-postanız onaylanana kadar bazı kategorilerde gönderi paylaşamayabilir veya sohbet edemeyebilirsiniz.", + "no-email-to-confirm": "Hesabınızda bir e-posta grubu yok. Hesap kurtarma için bir e-posta gereklidir ve bazı kategorilerde sohbet etmek ve gönderi paylaşmak için gerekli olabilir. Bir e-posta girmek için lütfen burayı tıklayın.", "user-doesnt-have-email": "\"%1\" kullanıcısı bir e-posta belirlememiş.", "email-confirm-failed": "E-posta adresinizi doğrulayamıyoruz. Lütfen daha sonra tekrar deneyin.", "confirm-email-already-sent": "E-posta onayı zaten gönderilmiş, yeni bir onay göndermek için lütfen %1 dakika bekleyin.", @@ -198,14 +198,14 @@ "topic-event-unrecognized": "Konu aktivitesi '%1' tanımlanamadı", "cant-set-child-as-parent": "Alt-kategoriyi üst kategori olarak ayarlayamazsınız!", "cant-set-self-as-parent": "Kendisini üst kategori olarak ayarlayamazsınız!", - "api.master-token-no-uid": "A master token was received without a corresponding `_uid` in the request body", - "api.400": "Something was wrong with the request payload you passed in.", + "api.master-token-no-uid": "İsteğe karşılık gelen bir \"_uid\" olmadan bir ana belirteç alındı", + "api.400": "İlettiğiniz istekle ilgili bir sorun vardı.", "api.401": "Geçerli bir giriş oturumu bulunamadı. Lütfen yeniden giriş yapıp tekrar deneyin.", - "api.403": "You are not authorised to make this call", - "api.404": "Invalid API call", - "api.426": "HTTPS is required for requests to the write api, please re-send your request via HTTPS", + "api.403": "Bu aramayı yapmak için yetkiniz yok", + "api.404": "Geçersiz API çağrısı", + "api.426": "Yazma API'sine yapılan istekler için HTTPS gereklidir, lütfen isteğinizi HTTPS aracılığıyla yeniden gönderin", "api.429": "Fazla sayıda istekte bulundunuz, lütfen daha sonra tekrar deneyiniz.", "api.500": "İsteğinizi gerçekleştirmeye çalışırken beklenmeyen bir hata ile karşılaşıldı.", - "api.501": "The route you are trying to call is not implemented yet, please try again tomorrow", - "api.503": "The route you are trying to call is not currently available due to a server configuration" + "api.501": "Aramaya çalıştığınız rota henüz uygulanmadı, lütfen yarın tekrar deneyin", + "api.503": "Aramaya çalıştığınız rota sunucu yapılandırması nedeniyle şu anda kullanılamıyor" } \ No newline at end of file diff --git a/public/language/tr/global.json b/public/language/tr/global.json index b8c2bbaff9..e8bab24f0d 100644 --- a/public/language/tr/global.json +++ b/public/language/tr/global.json @@ -70,7 +70,7 @@ "firstpost": "İlk ileti", "read_more": "daha fazla oku", "more": "Daha Fazla", - "none": "None", + "none": "Hiçbiri", "posted_ago_by_guest": "Ziyaretçi tarafından %1 yayımlandı", "posted_ago_by": "%2 tarafından %1 yayımlandı", "posted_ago": "%1 yayımlandı", diff --git a/public/language/tr/modules.json b/public/language/tr/modules.json index fdc0ff7dac..a35259de4b 100644 --- a/public/language/tr/modules.json +++ b/public/language/tr/modules.json @@ -54,7 +54,7 @@ "composer.formatting.strikethrough": "Üstüçizili", "composer.formatting.code": "Kod", "composer.formatting.link": "Bağlantı", - "composer.formatting.picture": "Image Link", + "composer.formatting.picture": "Görsel Linki", "composer.upload-picture": "Görsel Yükle", "composer.upload-file": "Dosya Yükle", "composer.zen_mode": "Tam ekran modu", diff --git a/public/language/tr/register.json b/public/language/tr/register.json index 242ac0af82..0d81d81ce0 100644 --- a/public/language/tr/register.json +++ b/public/language/tr/register.json @@ -20,9 +20,9 @@ "registration-added-to-queue": "Kayıt olma isteğiniz kabul listesine eklenmiştir. Yönetici tarafından kabul edildiğinizde e-posta alacaksınız.", "registration-queue-average-time": "Üyelik onayı için bekleyeceğiniz ortalama süre: %1 saat %2 dakika.", "registration-queue-auto-approve-time": "Forum üyeliğiniz %1 saat içerisinde tamamen aktifleştirilecektir. ", - "interstitial.intro": "We'd like some additional information in order to update your account…", - "interstitial.intro-new": "We'd like some additional information before we can create your account…", - "interstitial.errors-found": "Please review the entered information:", + "interstitial.intro": "Hesabınızı güncellemek için bazı ek bilgiler istiyoruz…", + "interstitial.intro-new": "Hesabınızı oluşturabilmemiz için önce bazı ek bilgiler istiyoruz…", + "interstitial.errors-found": "Lütfen girilen bilgileri inceleyin:", "gdpr_agree_data": "Bu web sitesinde kişisel bilgilerimin toplanmasını ve işlenmesini kabul ediyorum.", "gdpr_agree_email": "Bu web sitesinden özet ve bildirim e-postası almaya izin veriyorum.", "gdpr_consent_denied": "Bilgilerinizi toplamak/işlemek ve size e-posta göndermek için bu siteye onay vermelisiniz.", diff --git a/public/language/tr/topic.json b/public/language/tr/topic.json index 803a9e53af..0fbcb45d5c 100644 --- a/public/language/tr/topic.json +++ b/public/language/tr/topic.json @@ -20,8 +20,8 @@ "login-to-view": "🔒 Görüntülemek için giriş yap!", "edit": "Düzenle", "delete": "Sil", - "delete-event": "Delete Event", - "delete-event-confirm": "Are you sure you want to delete this event?", + "delete-event": "Etkinliği Sil", + "delete-event-confirm": "Bu etkinliği silmek istediğinizden emin misiniz?", "purge": "Temizle", "restore": "Geri Getir", "move": "Taşı", @@ -45,9 +45,9 @@ "unpinned-by": "Sabitlenme kaldırıldı", "deleted-by": "Silindi", "restored-by": "Tekrar Yüklendi", - "moved-from-by": "Moved from %1 by", + "moved-from-by": "%1 'den taşındı", "queued-by": "İleti onay için sıraya alındı →", - "backlink": "Referenced by", + "backlink": "başvurulan", "bookmark_instructions": "Bu konuda en son kaldığın yere dönmek için tıkla.", "flag-post": "Bu iletiyi şikayet et", "flag-user": "Bu kullanıcıyı şikayet et", @@ -139,7 +139,7 @@ "composer.handle_placeholder": "Kullanıcı adınızı buraya girin", "composer.discard": "Vazgeç", "composer.submit": "Gönder", - "composer.additional-options": "Additional Options", + "composer.additional-options": "Ekstra seçenekler", "composer.schedule": "Konu Zamanla", "composer.replying_to": "Yanıtlanan Başlık: %1", "composer.new_topic": "Yeni Başlık", @@ -160,7 +160,7 @@ "newest_to_oldest": "En yeniden en eskiye", "most_votes": "En çok oylanan", "most_posts": "En çok ileti yazılan", - "most_views": "Most Views", + "most_views": "Çok Görüntülenen", "stale.title": "Bunun yerine yeni bir başlık oluşturun?", "stale.warning": "Yanıtlamak istediğiniz başlık oldukça eski. Bu başlığa referans oluşturacak yeni bir başlık oluşturmak ister misiniz?", "stale.create": "Yeni bir başlık oluştur", @@ -180,5 +180,5 @@ "timeago_earlier": "%1 önce", "first-post": "İlk ileti", "last-post": "Son ileti", - "post-quick-reply": "Post quick reply" + "post-quick-reply": "Hızlı yanıt gönder" } \ No newline at end of file diff --git a/public/language/tr/user.json b/public/language/tr/user.json index ae99629a6b..dd6fef03b0 100644 --- a/public/language/tr/user.json +++ b/public/language/tr/user.json @@ -94,12 +94,12 @@ "digest_off": "Kapalı", "digest_daily": "Günlük", "digest_weekly": "Haftalık", - "digest_biweekly": "Bi-Weekly", + "digest_biweekly": "İki haftada bir", "digest_monthly": "Aylık", "has_no_follower": "Bu kullanıcının hiç takipçisi yok :(", "follows_no_one": "Bu kullanıcı kimseyi takip etmiyor :(", "has_no_posts": "Bu kullanıcı henüz herhangi bir ileti yazmamış :(", - "has_no_best_posts": "This user does not have any upvoted posts yet.", + "has_no_best_posts": "Bu kullanıcının herhangi bir gönderisi henüz olumlu oy almadı.", "has_no_topics": "Bu kullanıcı henüz hiçbir başlık açmamış :(", "has_no_watched_topics": "Bu kullanıcı henüz hiçbir başlığı takip etmiyor :(", "has_no_ignored_topics": "Bu kullanıcı henüz hiçbir başlığı yok saymamış.", @@ -183,7 +183,7 @@ "consent.export-uploads-success": "Yüklemeler aktarılmak üzere hazırlanıyor, işlem tamamlandığında bildirim alacaksınız!", "consent.export_posts": "Gönderileri Dışa Aktar (.csv)", "consent.export-posts-success": "İletiler aktarılmak üzere hazırlanıyor, işlem tamamlandığında bildirim alacaksınız!", - "emailUpdate.intro": "Please enter your email address below. This forum uses your email address for scheduled digest and notifications, as well as for account recovery in the event of a lost password.", - "emailUpdate.optional": "This field is optional. You are not obligated to provide your email address, but without a validated email, you will not be able to recover your account.", - "emailUpdate.change-instructions": "A confirmation email will be sent to the entered email address with a unique link. Accessing that link will confirm your ownership of the email address and it will become active on your account. At any time, you are able to update your email on file from within your account page." + "emailUpdate.intro": "Lütfen e-posta adresinizi aşağıya girin. Bu forum, e-posta adresinizi planlanmış özet ve bildirimler ile parolanın kaybolması durumunda hesap kurtarma için kullanır.", + "emailUpdate.optional": "Bu alan isteğe bağlıdır. E-posta adresinizi vermek zorunda değilsiniz, ancak doğrulanmış bir e-posta olmadan hesabınızı kurtaramazsınız.", + "emailUpdate.change-instructions": "Girilen e-posta adresine kişiye özel bir bağlantı içeren bir onay e-postası gönderilecektir. Bu bağlantıya erişmek, e-posta adresinin sahibi olduğunuzu onaylayacak ve hesabınızda etkin hale gelecektir. İstediğiniz zaman, hesap sayfanızdan kayıtlı e-postanızı güncelleyebilirsiniz." } \ No newline at end of file From 50b2ebf844c6d77056929cede32e83f29a66e1bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 28 Oct 2021 09:46:21 -0400 Subject: [PATCH 310/412] fix: remove unused code --- public/src/client/topic.js | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 5cc2da69a5..944bd9ad2a 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -32,12 +32,6 @@ define('forum/topic', [ navigator.disable(); components.get('navbar/title').find('span').text('').hide(); app.removeAlert('bookmark'); - - require(['search'], function (search) { - if (search.topicDOM.active) { - search.topicDOM.end(); - } - }); } }); @@ -79,18 +73,6 @@ define('forum/topic', [ }; function handleTopicSearch() { - $('.topic-search').off('click') - .on('click', '.prev', function () { - require(['search'], function (search) { - search.topicDOM.prev(); - }); - }) - .on('click', '.next', function () { - require(['search'], function (search) { - search.topicDOM.next(); - }); - }); - if (config.topicSearchEnabled) { require(['mousetrap'], function (mousetrap) { mousetrap.bind(['command+f', 'ctrl+f'], function (e) { From e8c17feedba203ce1a93017661c4c0587dc8c22b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 28 Oct 2021 12:00:51 -0400 Subject: [PATCH 311/412] refactor: use utils.debounce --- public/src/client/topic.js | 55 +++++++++++++------------------------- 1 file changed, 19 insertions(+), 36 deletions(-) diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 944bd9ad2a..6fe0310dd6 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -7,7 +7,6 @@ define('forum/topic', [ 'forum/topic/postTools', 'forum/topic/events', 'forum/topic/posts', - 'forum/topic/images', 'navigator', 'sort', 'components', @@ -15,17 +14,13 @@ define('forum/topic', [ 'hooks', ], function ( infinitescroll, threadTools, postTools, - events, posts, images, navigator, sort, + events, posts, navigator, sort, components, storage, hooks ) { - const Topic = {}; + const Topic = {}; let currentUrl = ''; $(window).on('action:ajaxify.start', function (ev, data) { - if (Topic.replaceURLTimeout) { - clearTimeout(Topic.replaceURLTimeout); - Topic.replaceURLTimeout = 0; - } events.removeListeners(); if (!String(data.url).startsWith('topic/')) { @@ -44,7 +39,7 @@ define('forum/topic', [ posts.onTopicPageLoad(components.get('post')); - navigator.init('[component="post"]', ajaxify.data.postcount, Topic.toTop, Topic.toBottom, Topic.navigatorCallback); + navigator.init('[component="post"]', ajaxify.data.postcount, Topic.toTop, Topic.toBottom, utils.debounce(Topic.navigatorCallback, 500)); postTools.init(tid); threadTools.init(tid, $('.topic')); @@ -61,11 +56,9 @@ define('forum/topic', [ addDropupHandler(); addRepliesHandler(); - - handleBookmark(tid); - $(window).on('scroll', updateTopicTitle); + $(window).on('scroll', utils.debounce(updateTopicTitle, 250)); handleTopicSearch(); @@ -192,41 +185,31 @@ define('forum/topic', [ } Topic.navigatorCallback = function (index, elementCount) { - const path = ajaxify.removeRelativePath(window.location.pathname.slice(1)); - if (!path.startsWith('topic')) { - return; - } - - if (navigator.scrollActive) { + if (!ajaxify.data.template.topic || navigator.scrollActive) { return; } const newUrl = 'topic/' + ajaxify.data.slug + (index > 1 ? ('/' + index) : ''); if (newUrl !== currentUrl) { - if (Topic.replaceURLTimeout) { - clearTimeout(Topic.replaceURLTimeout); - Topic.replaceURLTimeout = 0; - } currentUrl = newUrl; - Topic.replaceURLTimeout = setTimeout(function () { - if (index >= elementCount && app.user.uid) { - socket.emit('topics.markAsRead', [ajaxify.data.tid]); - } - updateUserBookmark(index); + if (index >= elementCount && app.user.uid) { + socket.emit('topics.markAsRead', [ajaxify.data.tid]); + } - Topic.replaceURLTimeout = 0; - if (ajaxify.data.updateUrlWithPostIndex && history.replaceState) { - let search = window.location.search || ''; - if (!config.usePagination) { - search = (search && !/^\?page=\d+$/.test(search) ? search : ''); - } + updateUserBookmark(index); - history.replaceState({ - url: newUrl + search, - }, null, window.location.protocol + '//' + window.location.host + config.relative_path + '/' + newUrl + search); + Topic.replaceURLTimeout = 0; + if (ajaxify.data.updateUrlWithPostIndex && history.replaceState) { + let search = window.location.search || ''; + if (!config.usePagination) { + search = (search && !/^\?page=\d+$/.test(search) ? search : ''); } - }, 500); + + history.replaceState({ + url: newUrl + search, + }, null, window.location.protocol + '//' + window.location.host + config.relative_path + '/' + newUrl + search); + } } }; From 755860f16b41c8c80ad20a779c7c8bb0da13c256 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Thu, 28 Oct 2021 16:30:45 +0000 Subject: [PATCH 312/412] fix(deps): update dependency autoprefixer to v10.4.0 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index cb89650f40..1ef42043c1 100644 --- a/install/package.json +++ b/install/package.json @@ -32,7 +32,7 @@ "ace-builds": "^1.4.12", "archiver": "^5.2.0", "async": "^3.2.0", - "autoprefixer": "10.3.7", + "autoprefixer": "10.4.0", "bcryptjs": "2.4.3", "benchpressjs": "2.4.3", "body-parser": "^1.19.0", From bc4b19b4d73c7a3c9709d2ee0ef45c892f1137fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 28 Oct 2021 15:12:12 -0400 Subject: [PATCH 313/412] fix: typo in flags --- src/api/flags.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/flags.js b/src/api/flags.js index 19a8887260..235030c9df 100644 --- a/src/api/flags.js +++ b/src/api/flags.js @@ -51,7 +51,7 @@ flagsApi.appendNote = async (caller, data) => { } } catch (e) { // Okay if not does not exist in database - if (!e.message === '[[error:invalid-data]]') { + if (e.message !== '[[error:invalid-data]]') { throw e; } } From 62ac9a8bbbd561520095516e925cd40b766ca313 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 28 Oct 2021 15:40:53 -0400 Subject: [PATCH 314/412] test: add test aliases.buildTargets --- test/meta.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test/meta.js b/test/meta.js index 841d7b11ef..86ea5a3637 100644 --- a/test/meta.js +++ b/test/meta.js @@ -602,4 +602,10 @@ describe('meta', () => { }); }); }); + + it('should log targets', (done) => { + const aliases = require('../src/meta/aliases'); + aliases.buildTargets(); + done(); + }); }); From 74aa12c95b2acd3dab01b283c33eb24a358411aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 28 Oct 2021 21:33:21 -0400 Subject: [PATCH 315/412] fix: hooks is sometimes undefined --- public/src/app.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index 63787b6fe3..bacbc2309d 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -593,11 +593,14 @@ app.cacheBuster = null; }); let ajaxified = false; - hooks.on('action:ajaxify.end', function () { - if (!ajaxify.isCold()) { - ajaxified = true; - } + require(['hooks'], function (hooks) { + hooks.on('action:ajaxify.end', function () { + if (!ajaxify.isCold()) { + ajaxified = true; + } + }); }); + inputEl.on('focus', function () { mousedownOnResults = false; const query = inputEl.val(); From d8d5f416cc595af0bdd35b77c2ade55b3c7fae9a Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Fri, 29 Oct 2021 09:06:56 +0000 Subject: [PATCH 316/412] Latest translations and fallbacks --- public/language/fr/admin/dashboard.json | 10 +++++----- public/language/fr/admin/manage/digest.json | 2 +- public/language/fr/admin/menu.json | 2 +- public/language/fr/admin/settings/cookies.json | 2 +- public/language/fr/admin/settings/email.json | 6 +++--- public/language/fr/admin/settings/general.json | 8 ++++---- public/language/fr/admin/settings/user.json | 2 +- public/language/fr/error.json | 4 ++-- public/language/fr/topic.json | 2 +- public/language/fr/user.json | 2 +- 10 files changed, 20 insertions(+), 20 deletions(-) diff --git a/public/language/fr/admin/dashboard.json b/public/language/fr/admin/dashboard.json index 3a4f7bf284..7328224f86 100644 --- a/public/language/fr/admin/dashboard.json +++ b/public/language/fr/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Total", "active-users.connections": "Connexions", - "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest-registered-users": "Utilisateurs invités vs enregistrés", + "guest": "Invité", "registered": "Enregistrés", "user-presence": "Présence des utilisateurs", @@ -68,7 +68,7 @@ "unread": "Non lus", "high-presence-topics": "Sujets populaires", - "popular-searches": "Popular Searches", + "popular-searches": "Recherches populaires", "graphs.page-views": "Pages vues", "graphs.page-views-registered": "Membres", @@ -76,14 +76,14 @@ "graphs.page-views-bot": "Robots", "graphs.unique-visitors": "Visiteurs uniques", "graphs.registered-users": "Utilisateurs enregistrés", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "Utilisateurs invités", "last-restarted-by": "Redémarré par", "no-users-browsing": "Aucun utilisateur connecté", "back-to-dashboard": "Retour au Tableau de bord", "details.no-users": "Aucun utilisateur ne s'est joint dans le délai sélectionné", "details.no-topics": "Aucun sujet n'a été publié dans la période sélectionnée", - "details.no-searches": "No searches have been made yet", + "details.no-searches": "Aucune recherche n'a encore été effectuée", "details.no-logins": "Aucune connexion n'a été enregistrée dans le délai sélectionné", "details.logins-static": "NodeBB n'enregistre que les données de session pendant %1 jours, et le tableau ci-dessous n'affichera donc que les dernières sessions actives", "details.logins-login-time": "Heure de connexion" diff --git a/public/language/fr/admin/manage/digest.json b/public/language/fr/admin/manage/digest.json index 0661b13ed8..2512debb1f 100644 --- a/public/language/fr/admin/manage/digest.json +++ b/public/language/fr/admin/manage/digest.json @@ -13,7 +13,7 @@ "resent-single": "Lettre d'activité envoyée", "resent-day": "Lettre d'activités quotidienne envoyée", "resent-week": "Lettre d'activité hebdomadaire envoyée", - "resent-biweek": "Bi-Weekly digest resent", + "resent-biweek": "Lettre d'activité envoyée deux fois par semaine", "resent-month": "Lettre d'activité mensuel envoyé", "null": "Jamais", "manual-run": "Lancer manuellement l'envoi:", diff --git a/public/language/fr/admin/menu.json b/public/language/fr/admin/menu.json index dc12d9e9e1..196f86ce5c 100644 --- a/public/language/fr/admin/menu.json +++ b/public/language/fr/admin/menu.json @@ -4,7 +4,7 @@ "dashboard/logins": "Connexions", "dashboard/users": "Utilisateurs", "dashboard/topics": "Sujets", - "dashboard/searches": "Searches", + "dashboard/searches": "Recherches", "section-general": "Général", "section-manage": "Gestion", diff --git a/public/language/fr/admin/settings/cookies.json b/public/language/fr/admin/settings/cookies.json index 797294c699..b337057dfc 100644 --- a/public/language/fr/admin/settings/cookies.json +++ b/public/language/fr/admin/settings/cookies.json @@ -4,7 +4,7 @@ "consent.message": "Message de notification", "consent.acceptance": "Message d'acceptation", "consent.link-text": "Texte du lien vers la politique de confidentialité", - "consent.link-url": "Policy Link URL", + "consent.link-url": "URL du lien Policy", "consent.blank-localised-default": "Laisser vide pour utiliser les textes localisés par défaut de NodeBB", "settings": "Réglages", "cookie-domain": "Domaine de session du cookie", diff --git a/public/language/fr/admin/settings/email.json b/public/language/fr/admin/settings/email.json index 1f5b030ed3..56956a04ca 100644 --- a/public/language/fr/admin/settings/email.json +++ b/public/language/fr/admin/settings/email.json @@ -6,7 +6,7 @@ "from-help": "Le nom de l’expéditeur à afficher dans l'e-mail", "smtp-transport": "Protocole SMTP", - "smtp-transport.enabled": "Enable SMTP Transport", + "smtp-transport.enabled": "Activer l'envoi via SMTP", "smtp-transport-help": "Vous pouvez sélectionner depuis une liste de services ou entrer un service personnalisé.", "smtp-transport.service": "Sélectionner un service", "smtp-transport.service-custom": "Service personnalisé", @@ -41,6 +41,6 @@ "require-email-address-warning": "Par défaut, les utilisateurs peuvent refuser de saisir une adresse e-mail. L'activation de cette option oblige de renseigner une une adresse e-mail lors de l'inscription. Ne garantit pas que l'utilisateur entrera adresse e-mail valide, ni même une adresse qu'il possède.", "include-unverified-emails": "Envoyer des mails aux destinataires qui n'ont pas explicitement confirmé leurs mails", "include-unverified-warning": "Par défaut, les utilisateurs dont les mails sont associés à leur compte ont déjà été vérifiés, mais il existe des situations où ce n'est pas le cas (par exemple, les connexions SSO, les utilisateurs bénéficiant de droits acquis, etc.). Activez ce paramètre à vos risques et périls – l'envoi de mails à des adresses non vérifiées peut constituer une violation des lois anti-spam régionales.", - "prompt": "Prompt users to enter or confirm their emails", - "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." + "prompt": "Inviter les utilisateurs à saisir ou à confirmer leurs emails", + "prompt-help": "Si un utilisateur n'a pas défini d'email ou si son email n'est pas confirmé, un avertissement s'affichera à l'écran." } diff --git a/public/language/fr/admin/settings/general.json b/public/language/fr/admin/settings/general.json index 232e29037a..0f871bec8c 100644 --- a/public/language/fr/admin/settings/general.json +++ b/public/language/fr/admin/settings/general.json @@ -3,9 +3,9 @@ "title": "Titre du site", "title.short": "Titre court", "title.short-placeholder": "Si aucun titre court n'est spécifié, le titre du site sera utilisé", - "title.url": "Title Link URL", + "title.url": "URL du lien du titre", "title.url-placeholder": "URL du titre du site", - "title.url-help": "When the title is clicked, send users to this address. If left blank, user will be sent to the forum index.
    Note: This is not the external URL used in emails, etc. That is set by the url property in config.json", + "title.url-help": "Lorsque le titre est cliqué, il renvoi les utilisateurs à cette adresse. Si laissé vide, l'utilisateur sera envoyé à l'index du forum.
    Remarque : il ne s'agit pas de l'URL externe utilisée dans les e-mails, etc. Elle est définie par la propriété url dans config.json", "title.name": "Nom de votre communauté", "title.show-in-header": "Afficher le titre du site dans l'en-tête", "browser-title": "Titre dans le navigateur", @@ -20,9 +20,9 @@ "logo.image": "Image", "logo.image-placeholder": "Chemin vers un logo à afficher dans l'en-tête du site", "logo.upload": "Télécharger", - "logo.url": "Logo Link URL", + "logo.url": "URL du lien du logo", "logo.url-placeholder": "L'URL du logo du site", - "logo.url-help": "When the logo is clicked, send users to this address. If left blank, user will be sent to the forum index.
    Note: This is not the external URL used in emails, etc. That is set by the url property in config.json", + "logo.url-help": "Lorsque le logo est cliqué, il renvoi les utilisateurs à cette adresse. Si laissé vide, l'utilisateur sera envoyé à l'index du forum.
    Remarque : il ne s'agit pas de l'URL externe utilisée dans les e-mails, etc. Elle est définie par la propriété url dans config.json", "logo.alt-text": "Texte alternatif (alt)", "log.alt-text-placeholder": "Texte alternatif pour l'accessibilité", "favicon": "Favicon", diff --git a/public/language/fr/admin/settings/user.json b/public/language/fr/admin/settings/user.json index 722b013d4b..0a736319e6 100644 --- a/public/language/fr/admin/settings/user.json +++ b/public/language/fr/admin/settings/user.json @@ -71,7 +71,7 @@ "digest-freq.off": "Désactivé", "digest-freq.daily": "Quotidien", "digest-freq.weekly": "Hebdomadaire", - "digest-freq.biweekly": "Bi-Weekly", + "digest-freq.biweekly": "Deux fois par semaine", "digest-freq.monthly": "Mensuel", "email-chat-notifs": "Envoyer un e-mail si un nouveau message de chat arrive lorsque je ne suis pas en ligne", "email-post-notif": "Envoyer un email lors de réponses envoyées aux sujets auxquels que je suis", diff --git a/public/language/fr/error.json b/public/language/fr/error.json index 0da22c466c..6f53fa2605 100644 --- a/public/language/fr/error.json +++ b/public/language/fr/error.json @@ -34,8 +34,8 @@ "email-invited": "Cet utilisateur a déjà été invité.", "email-not-confirmed": "La publication dans certaines catégories ou sujets sera activée après confirmation de e-mail, veuillez cliquer ici pour envoyer un e-mail de confirmation.", "email-not-confirmed-chat": "Il ne vous est pas possible d'utiliser le chat tant que votre adresse email n'a pas été vérifiée. Veuillez cliquer ici pour confirmer votre adresse email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Votre email n'a pas encore été confirmé, veuillez vérifier votre boîte mail. Vous ne pourrez pas poster ou discuter avant que votre email ne soit confirmé.", + "no-email-to-confirm": "Votre compte n'a pas d'adresse mail définie. Un mail est nécessaire pour la récupération du compte. Veuillez cliquer ici pour entrer un courriel.", "user-doesnt-have-email": "L'utilisateur « %1 » n'a pas d'adresse e-mail.", "email-confirm-failed": "Votre adresse email n'a pas pu être vérifiée. Veuillez ré-essayer plus tard.", "confirm-email-already-sent": "L'email de confirmation a déjà été envoyé. Veuillez attendre %1 minute(s) avant de redemander un nouvel envoi.", diff --git a/public/language/fr/topic.json b/public/language/fr/topic.json index f5cd794d55..c3157a0148 100644 --- a/public/language/fr/topic.json +++ b/public/language/fr/topic.json @@ -139,7 +139,7 @@ "composer.handle_placeholder": "Entrez votre nom/identifiant ici", "composer.discard": "Abandonner", "composer.submit": "Envoyer", - "composer.additional-options": "Additional Options", + "composer.additional-options": "Options additionnelles", "composer.schedule": "Planification", "composer.replying_to": "En réponse à %1", "composer.new_topic": "Nouveau sujet", diff --git a/public/language/fr/user.json b/public/language/fr/user.json index 17fbe49537..df75626619 100644 --- a/public/language/fr/user.json +++ b/public/language/fr/user.json @@ -94,7 +94,7 @@ "digest_off": "Désactivé", "digest_daily": "Quotidien", "digest_weekly": "Hebdomadaire", - "digest_biweekly": "Bi-Weekly", + "digest_biweekly": "Deux fois par semaine", "digest_monthly": "Mensuel", "has_no_follower": "Personne n'est abonné à cet utilisateur :(", "follows_no_one": "Cet utilisateur n'est abonné à personne :(", From 6a976a9db0340e34577961ce8d5d9479c78f7856 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 29 Oct 2021 10:56:03 -0400 Subject: [PATCH 317/412] fix: #9945, call authenticateRequest middleware for mount points in /api --- src/routes/api.js | 47 ++++++++++++++++++++++++----------------------- 1 file changed, 24 insertions(+), 23 deletions(-) diff --git a/src/routes/api.js b/src/routes/api.js index d80adc47ec..d2fdd340c9 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -6,29 +6,30 @@ const uploadsController = require('../controllers/uploads'); const helpers = require('./helpers'); module.exports = function (app, middleware, controllers) { + const middlewares = [middleware.authenticateRequest]; const router = express.Router(); app.use('/api', router); - router.get('/config', middleware.applyCSRF, middleware.authenticateRequest, helpers.tryRoute(controllers.api.getConfig)); + router.get('/config', [...middlewares, middleware.applyCSRF], helpers.tryRoute(controllers.api.getConfig)); - router.get('/self', helpers.tryRoute(controllers.user.getCurrentUser)); - router.get('/user/uid/:uid', middleware.canViewUsers, helpers.tryRoute(controllers.user.getUserByUID)); - router.get('/user/username/:username', middleware.canViewUsers, helpers.tryRoute(controllers.user.getUserByUsername)); - router.get('/user/email/:email', middleware.canViewUsers, helpers.tryRoute(controllers.user.getUserByEmail)); + router.get('/self', [...middlewares], helpers.tryRoute(controllers.user.getCurrentUser)); + router.get('/user/uid/:uid', [...middlewares, middleware.canViewUsers], helpers.tryRoute(controllers.user.getUserByUID)); + router.get('/user/username/:username', [...middlewares, middleware.canViewUsers], helpers.tryRoute(controllers.user.getUserByUsername)); + router.get('/user/email/:email', [...middlewares, middleware.canViewUsers], helpers.tryRoute(controllers.user.getUserByEmail)); - router.get('/user/uid/:userslug/export/posts', middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid, helpers.tryRoute(controllers.user.exportPosts)); - router.get('/user/uid/:userslug/export/uploads', middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid, helpers.tryRoute(controllers.user.exportUploads)); - router.get('/user/uid/:userslug/export/profile', middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid, helpers.tryRoute(controllers.user.exportProfile)); + router.get('/user/uid/:userslug/export/posts', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportPosts)); + router.get('/user/uid/:userslug/export/uploads', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportUploads)); + router.get('/user/uid/:userslug/export/profile', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportProfile)); - router.get('/categories/:cid/moderators', helpers.tryRoute(controllers.api.getModerators)); - router.get('/recent/posts/:term?', helpers.tryRoute(controllers.posts.getRecentPosts)); - router.get('/unread/total', middleware.authenticateRequest, middleware.ensureLoggedIn, helpers.tryRoute(controllers.unread.unreadTotal)); - router.get('/topic/teaser/:topic_id', helpers.tryRoute(controllers.topics.teaser)); - router.get('/topic/pagination/:topic_id', helpers.tryRoute(controllers.topics.pagination)); + router.get('/categories/:cid/moderators', [...middlewares], helpers.tryRoute(controllers.api.getModerators)); + router.get('/recent/posts/:term?', [...middlewares], helpers.tryRoute(controllers.posts.getRecentPosts)); + router.get('/unread/total', [...middlewares, middleware.ensureLoggedIn], helpers.tryRoute(controllers.unread.unreadTotal)); + router.get('/topic/teaser/:topic_id', [...middlewares], helpers.tryRoute(controllers.topics.teaser)); + router.get('/topic/pagination/:topic_id', [...middlewares], helpers.tryRoute(controllers.topics.pagination)); const multipart = require('connect-multiparty'); const multipartMiddleware = multipart(); - const middlewares = [ + const postMiddlewares = [ middleware.maintenanceMode, multipartMiddleware, middleware.validateFiles, @@ -37,13 +38,13 @@ module.exports = function (app, middleware, controllers) { ]; router.post('/post/upload', middlewares, helpers.tryRoute(uploadsController.uploadPost)); - router.post('/user/:userslug/uploadpicture', - middlewares.concat([ - middleware.exposeUid, - middleware.authenticateRequest, - middleware.ensureLoggedIn, - middleware.canViewUsers, - middleware.checkAccountPermissions, - ]), - helpers.tryRoute(controllers.accounts.edit.uploadPicture)); + router.post('/user/:userslug/uploadpicture', [ + ...middlewares, + ...postMiddlewares, + middleware.exposeUid, + middleware.authenticateRequest, + middleware.ensureLoggedIn, + middleware.canViewUsers, + middleware.checkAccountPermissions, + ], helpers.tryRoute(controllers.accounts.edit.uploadPicture)); }; From 60352eca5462daeee144370d4db2d55118c0392d Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 29 Oct 2021 11:16:37 -0400 Subject: [PATCH 318/412] fix: double invocation of authenticateRequest --- src/routes/api.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/routes/api.js b/src/routes/api.js index d2fdd340c9..fa76030013 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -42,7 +42,6 @@ module.exports = function (app, middleware, controllers) { ...middlewares, ...postMiddlewares, middleware.exposeUid, - middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.canViewUsers, middleware.checkAccountPermissions, From 0ee85d5a0b6811d44ea53ac6e558c4317f7a107b Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 29 Oct 2021 14:11:55 -0400 Subject: [PATCH 319/412] fix: #9950, rename account export routes to remove `uid/` prefix --- public/openapi/read.yaml | 14 ++++++++------ .../read/user/uid/userslug/export/type.yaml | 19 +++++++++++++++++++ .../user/{uid => }/userslug/export/posts.yaml | 0 .../{uid => }/userslug/export/profile.yaml | 0 .../{uid => }/userslug/export/uploads.yaml | 0 src/routes/api.js | 13 ++++++++++--- src/socket.io/user/profile.js | 2 +- 7 files changed, 38 insertions(+), 10 deletions(-) create mode 100644 public/openapi/read/user/uid/userslug/export/type.yaml rename public/openapi/read/user/{uid => }/userslug/export/posts.yaml (100%) rename public/openapi/read/user/{uid => }/userslug/export/profile.yaml (100%) rename public/openapi/read/user/{uid => }/userslug/export/uploads.yaml (100%) diff --git a/public/openapi/read.yaml b/public/openapi/read.yaml index 857621dd86..2adc245b18 100644 --- a/public/openapi/read.yaml +++ b/public/openapi/read.yaml @@ -180,12 +180,14 @@ paths: $ref: 'read/user/username/username.yaml' "/api/user/email/{email}": $ref: 'read/user/email/email.yaml' - "/api/user/uid/{userslug}/export/posts": - $ref: 'read/user/uid/userslug/export/posts.yaml' - "/api/user/uid/{userslug}/export/uploads": - $ref: 'read/user/uid/userslug/export/uploads.yaml' - "/api/user/uid/{userslug}/export/profile": - $ref: 'read/user/uid/userslug/export/profile.yaml' + "/api/user/{userslug}/export/posts": + $ref: 'read/user/userslug/export/posts.yaml' + "/api/user/{userslug}/export/uploads": + $ref: 'read/user/userslug/export/uploads.yaml' + "/api/user/{userslug}/export/profile": + $ref: 'read/user/userslug/export/profile.yaml' + "/api/user/uid/{userslug}/export/{type}": + $ref: 'read/user/uid/userslug/export/type.yaml' /api/categories: $ref: 'read/categories.yaml' "/api/categories/{cid}/moderators": diff --git a/public/openapi/read/user/uid/userslug/export/type.yaml b/public/openapi/read/user/uid/userslug/export/type.yaml new file mode 100644 index 0000000000..f859087247 --- /dev/null +++ b/public/openapi/read/user/uid/userslug/export/type.yaml @@ -0,0 +1,19 @@ +get: + tags: + - deprecated + summary: Export a user's posts (.csv) + parameters: + - name: userslug + in: path + required: true + schema: + type: string + example: admin + responses: + "200": + description: "A CSV file containing a user's posts" + content: + text/csv: + schema: + type: string + format: binary \ No newline at end of file diff --git a/public/openapi/read/user/uid/userslug/export/posts.yaml b/public/openapi/read/user/userslug/export/posts.yaml similarity index 100% rename from public/openapi/read/user/uid/userslug/export/posts.yaml rename to public/openapi/read/user/userslug/export/posts.yaml diff --git a/public/openapi/read/user/uid/userslug/export/profile.yaml b/public/openapi/read/user/userslug/export/profile.yaml similarity index 100% rename from public/openapi/read/user/uid/userslug/export/profile.yaml rename to public/openapi/read/user/userslug/export/profile.yaml diff --git a/public/openapi/read/user/uid/userslug/export/uploads.yaml b/public/openapi/read/user/userslug/export/uploads.yaml similarity index 100% rename from public/openapi/read/user/uid/userslug/export/uploads.yaml rename to public/openapi/read/user/userslug/export/uploads.yaml diff --git a/src/routes/api.js b/src/routes/api.js index fa76030013..31871d1fc8 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -1,6 +1,7 @@ 'use strict'; const express = require('express'); +const winston = require('winston'); const uploadsController = require('../controllers/uploads'); const helpers = require('./helpers'); @@ -17,9 +18,15 @@ module.exports = function (app, middleware, controllers) { router.get('/user/username/:username', [...middlewares, middleware.canViewUsers], helpers.tryRoute(controllers.user.getUserByUsername)); router.get('/user/email/:email', [...middlewares, middleware.canViewUsers], helpers.tryRoute(controllers.user.getUserByEmail)); - router.get('/user/uid/:userslug/export/posts', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportPosts)); - router.get('/user/uid/:userslug/export/uploads', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportUploads)); - router.get('/user/uid/:userslug/export/profile', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportProfile)); + router.get('/user/:userslug/export/posts', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportPosts)); + router.get('/user/:userslug/export/uploads', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportUploads)); + router.get('/user/:userslug/export/profile', [...middlewares, middleware.authenticateRequest, middleware.ensureLoggedIn, middleware.checkAccountPermissions, middleware.exposeUid], helpers.tryRoute(controllers.user.exportProfile)); + + // Deprecated, remove in v1.20.0 + router.get('/user/uid/:userslug/export/:type', (req, res) => { + winston.warn(`[router] \`/api/user/uid/${req.params.userslug}/export/${req.params.type}\` is deprecated, call it \`/api/user/${req.params.userslug}/export/${req.params.type}\`instead.`); + res.redirect(`/api/user/${req.params.userslug}/export/${req.params.type}`); + }); router.get('/categories/:cid/moderators', [...middlewares], helpers.tryRoute(controllers.api.getModerators)); router.get('/recent/posts/:term?', [...middlewares], helpers.tryRoute(controllers.posts.getRecentPosts)); diff --git a/src/socket.io/user/profile.js b/src/socket.io/user/profile.js index 2de4160ba5..0bce7240ff 100644 --- a/src/socket.io/user/profile.js +++ b/src/socket.io/user/profile.js @@ -140,7 +140,7 @@ module.exports = function (SocketUser) { const userData = await user.getUserFields(data.uid, ['username', 'userslug']); const n = await notifications.create({ bodyShort: `[[notifications:${type}-exported, ${userData.username}]]`, - path: `/api/user/uid/${userData.userslug}/export/${type}`, + path: `/api/user/${userData.userslug}/export/${type}`, nid: `${type}:export:${data.uid}`, from: data.uid, }); From 591424cea1d99a272bccfcfc8da603c6d977be1b Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 29 Oct 2021 14:21:42 -0400 Subject: [PATCH 320/412] chore: fix type.yaml example and summary --- .../openapi/read/user/uid/userslug/export/type.yaml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/public/openapi/read/user/uid/userslug/export/type.yaml b/public/openapi/read/user/uid/userslug/export/type.yaml index f859087247..e0ea7d93d1 100644 --- a/public/openapi/read/user/uid/userslug/export/type.yaml +++ b/public/openapi/read/user/uid/userslug/export/type.yaml @@ -1,7 +1,7 @@ get: tags: - deprecated - summary: Export a user's posts (.csv) + summary: Export a user's posts/profile/uploads (.csv) parameters: - name: userslug in: path @@ -10,10 +10,10 @@ get: type: string example: admin responses: - "200": - description: "A CSV file containing a user's posts" - content: - text/csv: + "302": + description: A redirect to the new URL format (without the `/uid` prefix) + headers: + Location: schema: type: string - format: binary \ No newline at end of file + example: /api/user/admin/export/posts \ No newline at end of file From 485b6ced1db9586e1cd3adfe8ca2de9906ca1970 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 29 Oct 2021 14:23:22 -0400 Subject: [PATCH 321/412] fix: broken post uploads due to 6a976a9db0340e34577961ce8d5d9479c78f7856 --- src/routes/api.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/api.js b/src/routes/api.js index 31871d1fc8..caab9c66a3 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -44,7 +44,7 @@ module.exports = function (app, middleware, controllers) { middleware.applyCSRF, ]; - router.post('/post/upload', middlewares, helpers.tryRoute(uploadsController.uploadPost)); + router.post('/post/upload', postMiddlewares, helpers.tryRoute(uploadsController.uploadPost)); router.post('/user/:userslug/uploadpicture', [ ...middlewares, ...postMiddlewares, From 10bb8cf747f2e09ea5790def7463b9e3aff49131 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 29 Oct 2021 15:18:40 -0400 Subject: [PATCH 322/412] test: fix account export test routes --- test/controllers.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/controllers.js b/test/controllers.js index e95840bf7b..452b43d302 100644 --- a/test/controllers.js +++ b/test/controllers.js @@ -1316,7 +1316,7 @@ describe('Controllers', () => { }); it('should export users posts', (done) => { - request(`${nconf.get('url')}/api/user/uid/foo/export/posts`, { jar: jar }, (err, res, body) => { + request(`${nconf.get('url')}/api/user/foo/export/posts`, { jar: jar }, (err, res, body) => { assert.ifError(err); assert.equal(res.statusCode, 200); assert(body); @@ -1325,7 +1325,7 @@ describe('Controllers', () => { }); it('should export users uploads', (done) => { - request(`${nconf.get('url')}/api/user/uid/foo/export/uploads`, { jar: jar }, (err, res, body) => { + request(`${nconf.get('url')}/api/user/foo/export/uploads`, { jar: jar }, (err, res, body) => { assert.ifError(err); assert.equal(res.statusCode, 200); assert(body); @@ -1334,7 +1334,7 @@ describe('Controllers', () => { }); it('should export users profile', (done) => { - request(`${nconf.get('url')}/api/user/uid/foo/export/profile`, { jar: jar }, (err, res, body) => { + request(`${nconf.get('url')}/api/user/foo/export/profile`, { jar: jar }, (err, res, body) => { assert.ifError(err); assert.equal(res.statusCode, 200); assert(body); From 1452557838f427e7a0f31df66948421712f68441 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Sat, 30 Oct 2021 09:06:24 +0000 Subject: [PATCH 323/412] Latest translations and fallbacks --- public/language/vi/admin/dashboard.json | 10 +++++----- public/language/vi/admin/menu.json | 2 +- public/language/vi/admin/settings/email.json | 4 ++-- public/language/vi/error.json | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/public/language/vi/admin/dashboard.json b/public/language/vi/admin/dashboard.json index a3d4dc5c28..7ab9f47374 100644 --- a/public/language/vi/admin/dashboard.json +++ b/public/language/vi/admin/dashboard.json @@ -56,8 +56,8 @@ "active-users.total": "Tổng", "active-users.connections": "Kết nối", - "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest-registered-users": "Khách vs Người dùng đã đăng ký", + "guest": "Khách", "registered": "Đã đăng ký", "user-presence": "Người Dùng Có Mặt", @@ -68,7 +68,7 @@ "unread": "Chưa đọc", "high-presence-topics": "Chủ Đề Hiện Diện Cao", - "popular-searches": "Popular Searches", + "popular-searches": "Tìm kiếm Phổ biến", "graphs.page-views": "Xem Trang", "graphs.page-views-registered": "Đã Đăng Ký Xem Trang", @@ -76,14 +76,14 @@ "graphs.page-views-bot": "Bot Xem Trang", "graphs.unique-visitors": "Khách Truy Cập Duy Nhất", "graphs.registered-users": "Thành Viên Chính Thức", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "Người dùng khách", "last-restarted-by": "Khởi động lại lần cuối bởi", "no-users-browsing": "Người không xem bài", "back-to-dashboard": "Quay lại Bảng điều khiển", "details.no-users": "Không có người dùng nào tham gia trong khung thời gian đã chọn", "details.no-topics": "Không có chủ đề nào được đăng trong khung thời gian đã chọn", - "details.no-searches": "No searches have been made yet", + "details.no-searches": "Chưa có tìm kiếm nào", "details.no-logins": "Không có thông tin đăng nhập nào được ghi lại trong khung thời gian đã chọn", "details.logins-static": "NodeBB chỉ lưu dữ liệu phiên trong %1 ngày và do đó, bảng này bên dưới sẽ chỉ hiển thị các phiên hoạt động gần đây nhất", "details.logins-login-time": "Thời gian đăng nhập" diff --git a/public/language/vi/admin/menu.json b/public/language/vi/admin/menu.json index 2e71acff00..d44cc4d246 100644 --- a/public/language/vi/admin/menu.json +++ b/public/language/vi/admin/menu.json @@ -4,7 +4,7 @@ "dashboard/logins": "Đăng nhập", "dashboard/users": "Người dùng", "dashboard/topics": "Chủ đề", - "dashboard/searches": "Searches", + "dashboard/searches": "Tìm kiếm", "section-general": "Chung", "section-manage": "Quản lý", diff --git a/public/language/vi/admin/settings/email.json b/public/language/vi/admin/settings/email.json index 066d64e9f7..07682dcf26 100644 --- a/public/language/vi/admin/settings/email.json +++ b/public/language/vi/admin/settings/email.json @@ -41,6 +41,6 @@ "require-email-address-warning": "Mặc định, người dùng có thể chọn không nhập địa chỉ email. Bật tùy chọn này nghĩa là họ buộc phải nhập địa chỉ email để đăng ký. Việc này không chắc người dùng sẽ nhập địa chỉ email thực, hoặc không phải địa chỉ mà họ sở hữu.", "include-unverified-emails": "Gửi email đến những người nhận chưa xác nhận rõ ràng email của họ", "include-unverified-warning": "Theo mặc định, người dùng có email được liên kết với tài khoản của họ đã được xác minh, nhưng có những trường hợp không phải như vậy (ví dụ: đăng nhập SSO, người dùng phổ thông, v.v.). Bạn tự chịu rủi ro khi bật cài đặt này – gửi email đến các địa chỉ chưa được xác minh có thể vi phạm luật chống thư rác trong khu vực.", - "prompt": "Prompt users to enter or confirm their emails", - "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." + "prompt": "Nhắc người dùng nhập hoặc xác nhận email của họ", + "prompt-help": "Nếu người dùng chưa cung cấp email hoặc email của họ chưa được xác nhận, một cảnh báo sẽ được hiển thị trên màn hình." } diff --git a/public/language/vi/error.json b/public/language/vi/error.json index 6dd9b00f2d..8da98da748 100644 --- a/public/language/vi/error.json +++ b/public/language/vi/error.json @@ -34,8 +34,8 @@ "email-invited": "Email đã được mời", "email-not-confirmed": "Đăng trong một số danh mục hoặc chủ đề được bật sau khi email của bạn được xác nhận, vui lòng nhấp vào đây để gửi email xác nhận.", "email-not-confirmed-chat": "Bạn không thể trò chuyện cho đến khi email của bạn được xác nhận, vui lòng nhấp vào đây để xác nhận email của bạn.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", + "email-not-confirmed-email-sent": "Email của bạn vẫn chưa được xác nhận, vui lòng kiểm tra hộp thư đến của bạn để biết email xác nhận. Bạn có thể không đăng được trong một số danh mục hoặc trò chuyện cho đến khi email của bạn được xác nhận.", + "no-email-to-confirm": "Tài khoản của bạn chưa có email. Email cần dùng lúc khôi phục tài khoản và có thể cần để trò chuyện và đăng bài trong một số danh mục. Vui lòng bấm vào đây để nhập email.", "user-doesnt-have-email": "Người dùng \"%1\" chưa đặt email.", "email-confirm-failed": "Chúng tôi không thể xác nhận email của bạn, vui lòng thử lại sau.", "confirm-email-already-sent": "Email xác nhận đã được gửi, vui lòng chờ %1 phút để yêu cầu gửi lại.", From a7f235dbac4dfa23ad0b839a5d56331d0cdf7a40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Sun, 31 Oct 2021 10:51:16 -0400 Subject: [PATCH 324/412] fix: topic events not rendered in infinitescroll --- public/src/client/topic/posts.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/public/src/client/topic/posts.js b/public/src/client/topic/posts.js index 0914497bb2..b84953e915 100644 --- a/public/src/client/topic/posts.js +++ b/public/src/client/topic/posts.js @@ -207,7 +207,8 @@ define('forum/topic/posts', [ app.parseAndTranslate('topic', 'posts', Object.assign({}, ajaxify.data, data), function (html) { html = html.filter(function () { const pid = $(this).attr('data-pid'); - return pid && $('[component="post"][data-pid="' + pid + '"]').length === 0; + const isPost = $(this).is('[component="post"]'); + return !isPost || (pid && $('[component="post"][data-pid="' + pid + '"]').length === 0); }); if (after) { From 89399c0ed511cc2ab60b2ccd0344b0e6741212bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Sun, 31 Oct 2021 15:09:33 -0400 Subject: [PATCH 325/412] fix: #9954, get next post timestamp fixes topic events being inserted in after first page but at the wrong spot --- public/src/modules/helpers.js | 2 +- src/topics/index.js | 17 +++++++++++++++++ src/topics/posts.js | 1 + 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/public/src/modules/helpers.js b/public/src/modules/helpers.js index b1778c92b1..34781ba92d 100644 --- a/public/src/modules/helpers.js +++ b/public/src/modules/helpers.js @@ -212,7 +212,7 @@ function renderTopicEvents(index) { const start = this.posts[index].timestamp; - const end = this.posts[index + 1] ? this.posts[index + 1].timestamp : Date.now(); + const end = this.posts[index].nextPostTimestamp; const events = this.events.filter(event => event.timestamp >= start && event.timestamp < end); if (!events.length) { return ''; diff --git a/src/topics/index.js b/src/topics/index.js index 85aa31aa2a..ddc432bfd4 100644 --- a/src/topics/index.js +++ b/src/topics/index.js @@ -240,9 +240,26 @@ async function getMainPostAndReplies(topic, set, uid, start, stop, reverse) { Topics.calculatePostIndices(replies, repliesStart); + await Topics.addNextPostTimestamp(postData, set, reverse); return await Topics.addPostData(postData, uid); } +Topics.addNextPostTimestamp = async function (postData, set, reverse) { + if (!postData.length) { + return; + } + postData.forEach((p, index) => { + if (p && postData[index + 1]) { + p.nextPostTimestamp = postData[index + 1].timestamp; + } + }); + const lastPost = postData[postData.length - 1]; + if (lastPost && lastPost.index) { + const data = await db[reverse ? 'getSortedSetRevRangeWithScores' : 'getSortedSetRangeWithScores'](set, lastPost.index, lastPost.index); + lastPost.nextPostTimestamp = data.length ? data[0].score : Date.now(); + } +}; + async function getDeleter(topicData) { if (!parseInt(topicData.deleterUid, 10)) { return null; diff --git a/src/topics/posts.js b/src/topics/posts.js index 2384dead48..dc947c6e67 100644 --- a/src/topics/posts.js +++ b/src/topics/posts.js @@ -24,6 +24,7 @@ module.exports = function (Topics) { const postData = await posts.getPostsFromSet(set, start, stop, uid, reverse); Topics.calculatePostIndices(postData, start); + await Topics.addNextPostTimestamp(postData, set, reverse); return await Topics.addPostData(postData, uid); }; From 3d611ab70eb9373d37e7752e08a71e9e8c7160f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Sun, 31 Oct 2021 16:13:16 -0400 Subject: [PATCH 326/412] fix: events for just topic with main post --- src/topics/index.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/topics/index.js b/src/topics/index.js index ddc432bfd4..06a6879c6c 100644 --- a/src/topics/index.js +++ b/src/topics/index.js @@ -254,9 +254,12 @@ Topics.addNextPostTimestamp = async function (postData, set, reverse) { } }); const lastPost = postData[postData.length - 1]; - if (lastPost && lastPost.index) { - const data = await db[reverse ? 'getSortedSetRevRangeWithScores' : 'getSortedSetRangeWithScores'](set, lastPost.index, lastPost.index); - lastPost.nextPostTimestamp = data.length ? data[0].score : Date.now(); + if (lastPost) { + lastPost.nextPostTimestamp = Date.now(); + if (lastPost.index) { + const data = await db[reverse ? 'getSortedSetRevRangeWithScores' : 'getSortedSetRangeWithScores'](set, lastPost.index, lastPost.index); + lastPost.nextPostTimestamp = data.length ? data[0].score : lastPost.nextPostTimestamp; + } } }; From 2ca40c672918b9dd75604ad5bab322454c03a21c Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Mon, 1 Nov 2021 09:07:17 +0000 Subject: [PATCH 327/412] Latest translations and fallbacks --- public/language/it/admin/settings/email.json | 4 ++-- public/language/it/error.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/public/language/it/admin/settings/email.json b/public/language/it/admin/settings/email.json index b203c44bfb..2d2eae1612 100644 --- a/public/language/it/admin/settings/email.json +++ b/public/language/it/admin/settings/email.json @@ -41,6 +41,6 @@ "require-email-address-warning": "Per impostazione predefinita, gli utenti possono rinunciare a inserire un indirizzo email. Abilitare questa opzione significa che devono inserire un indirizzo email per procedere con la registrazione. Non assicura che l'utente inserisca un indirizzo email reale, e nemmeno un indirizzo che possiede.", "include-unverified-emails": "Invia email a destinatari che non hanno confermato esplicitamente le loro email", "include-unverified-warning": "Per impostazione predefinita, gli utenti con email associate al loro account sono già stati verificati, ma ci sono situazioni in cui ciò non è vero (ad esempio accessi SSO, vecchi utenti, ecc.). Abilita questa impostazione a tuo rischio e pericolo – l'invio di email a indirizzi non verificati può essere una violazione delle leggi regionali anti-spam.", - "prompt": "Prompt users to enter or confirm their emails", - "prompt-help": "If a user does not have an email set, or their email is not confirmed, a warning will be shown on screen." + "prompt": "Chiedi agli utenti di inserire o confermare le loro email", + "prompt-help": "Se un utente non ha impostato un'email, o la sua email non è confermata, sarà mostrato un avviso sullo schermo." } diff --git a/public/language/it/error.json b/public/language/it/error.json index f05b5a3e1e..2ce566199d 100644 --- a/public/language/it/error.json +++ b/public/language/it/error.json @@ -34,8 +34,8 @@ "email-invited": "L'email è già stata invitata", "email-not-confirmed": "Sarai abilitato a postare in alcune categorie o discussioni una volta che la tua email sarà confermata, per favore clicca qui per inviare una email di conferma.", "email-not-confirmed-chat": "Non puoi chattare finché non confermi la tua email, per favore clicca qui per confermare la tua email.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", + "email-not-confirmed-email-sent": "La tua email non è stata ancora confermata, controlla la tua casella di posta per l'email di conferma. Potresti non essere in grado di postare in alcune categorie o chattare fino a quando la tua email non sarà confermata.", + "no-email-to-confirm": "Il tuo account non ha un'email impostata. Un'email è necessaria per il recupero dell'account, e può essere necessaria per chattare e postare in alcune categorie. Clicca qui per inserire un'email.", "user-doesnt-have-email": "L'utente \"%1\" non ha impostato un email.", "email-confirm-failed": "Non abbiamo potuto confermare la tua email, per favore riprovaci più tardi.", "confirm-email-already-sent": "Email di conferma già inviata, per favore attendere %1 minuto(i) per inviarne un'altra.", From 7d468e7203db0573ff0c64dcaa799628fc9302a4 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Mon, 1 Nov 2021 16:49:25 +0000 Subject: [PATCH 328/412] chore(deps): update dependency jsdom to v18.0.1 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 1ef42043c1..b825f4a98f 100644 --- a/install/package.json +++ b/install/package.json @@ -151,7 +151,7 @@ "grunt": "1.4.1", "grunt-contrib-watch": "1.1.0", "husky": "7.0.4", - "jsdom": "18.0.0", + "jsdom": "18.0.1", "lint-staged": "11.2.6", "mocha": "9.1.3", "mocha-lcov-reporter": "1.3.0", From 8c67031609da30d788561459f8bb76e9a69253de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 1 Nov 2021 15:09:05 -0400 Subject: [PATCH 329/412] feat: show posts previews if enabled on mouse over --- install/data/defaults.json | 1 + .../language/en-GB/admin/settings/post.json | 1 + public/src/client/topic.js | 57 ++++++++++++++++++- src/controllers/topics.js | 1 + src/socket.io/posts.js | 16 ++++++ src/views/admin/settings/post.tpl | 6 ++ src/views/partials/topic/post-preview.tpl | 13 +++++ 7 files changed, 94 insertions(+), 1 deletion(-) create mode 100644 src/views/partials/topic/post-preview.tpl diff --git a/install/data/defaults.json b/install/data/defaults.json index 3b92872280..52b7683954 100644 --- a/install/data/defaults.json +++ b/install/data/defaults.json @@ -69,6 +69,7 @@ "gdpr_enabled": 1, "allowProfileImageUploads": 1, "teaserPost": "last-reply", + "showPostPreviewsOnHover": 1, "allowPrivateGroups": 1, "unreadCutoff": 2, "bookmarkThreshold": 5, diff --git a/public/language/en-GB/admin/settings/post.json b/public/language/en-GB/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/en-GB/admin/settings/post.json +++ b/public/language/en-GB/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 6fe0310dd6..6661b43d65 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -12,10 +12,11 @@ define('forum/topic', [ 'components', 'storage', 'hooks', + 'api', ], function ( infinitescroll, threadTools, postTools, events, posts, navigator, sort, - components, storage, hooks + components, storage, hooks, api ) { const Topic = {}; let currentUrl = ''; @@ -55,6 +56,7 @@ define('forum/topic', [ addParentHandler(); addDropupHandler(); addRepliesHandler(); + addPostsPreviewHandler(); handleBookmark(tid); @@ -172,6 +174,59 @@ define('forum/topic', [ }); } + function addPostsPreviewHandler() { + if (!ajaxify.data.showPostPreviewsOnHover) { + return; + } + let timeoutId = 0; + $('[component="topic"]').on('mouseenter', '[component="post"] a, [component="topic/event"] a', async function () { + const link = $(this); + + async function renderPost(pid) { + const postData = await socket.emit('posts.getPostSummaryByPid', { pid: pid }); + if (postData) { + const tooltip = await app.parseAndTranslate('partials/topic/post-preview', { post: postData }); + tooltip.hide().find('.timeago').timeago(); + tooltip.appendTo($('body')).fadeIn(300); + const postContent = link.parents('[component="topic"]').find('[component="post/content"]').first(); + const postRect = postContent.offset(); + const postWidth = postContent.width(); + const linkRect = link.offset(); + tooltip.css({ + top: linkRect.top + 30, + left: postRect.left, + width: postWidth, + }); + } + } + + const href = link.attr('href'); + const pathname = utils.urlToLocation(href).pathname; + $('#post-tooltip').remove(); + const postMatch = pathname && pathname.match(/\/post\/([\d]+)/); + const topicMatch = pathname && pathname.match(/\/topic\/([\d]+)/); + if (postMatch) { + const pid = postMatch[1]; + if (parseInt(link.parents('[component="post"]').attr('data-pid'), 10) === parseInt(pid, 10)) { + return; // dont render self post + } + + timeoutId = setTimeout(async () => { + renderPost(pid); + }, 300); + } else if (topicMatch) { + timeoutId = setTimeout(async () => { + const tid = topicMatch[1]; + const topicData = await api.get('/topics/' + tid, {}); + renderPost(topicData.mainPid); + }, 300); + } + }).on('mouseleave', '[component="post"] a, [component="topic/event"] a', function () { + clearTimeout(timeoutId); + $('#post-tooltip').remove(); + }); + } + function updateTopicTitle() { const span = components.get('navbar/title').find('span'); if ($(window).scrollTop() > 50 && span.hasClass('hidden')) { diff --git a/src/controllers/topics.js b/src/controllers/topics.js index fa7a9b6d68..291acf78cf 100644 --- a/src/controllers/topics.js +++ b/src/controllers/topics.js @@ -96,6 +96,7 @@ topicsController.get = async function getTopic(req, res, next) { topicData.updateUrlWithPostIndex = settings.updateUrlWithPostIndex; topicData.allowMultipleBadges = meta.config.allowMultipleBadges === 1; topicData.privateUploads = meta.config.privateUploads === 1; + topicData.showPostPreviewsOnHover = meta.config.showPostPreviewsOnHover === 1; topicData.rssFeedUrl = `${relative_path}/topic/${topicData.tid}.rss`; if (req.loggedIn) { topicData.rssFeedUrl += `?uid=${req.uid}&token=${rssToken}`; diff --git a/src/socket.io/posts.js b/src/socket.io/posts.js index a4ab025cc4..9fc33293cf 100644 --- a/src/socket.io/posts.js +++ b/src/socket.io/posts.js @@ -98,6 +98,22 @@ SocketPosts.getPostSummaryByIndex = async function (socket, data) { return postsData[0]; }; +SocketPosts.getPostSummaryByPid = async function (socket, data) { + if (!data || !data.pid) { + throw new Error('[[error:invalid-data]]'); + } + const { pid } = data; + const tid = await posts.getPostField(pid, 'tid'); + const topicPrivileges = await privileges.topics.get(tid, socket.uid); + if (!topicPrivileges['topics:read']) { + throw new Error('[[error:no-privileges]]'); + } + + const postsData = await posts.getPostSummaryByPids([pid], socket.uid, { stripTags: false }); + posts.modifyPostByPrivilege(postsData[0], topicPrivileges); + return postsData[0]; +}; + SocketPosts.getPost = async function (socket, pid) { sockets.warnDeprecated(socket, 'GET /api/v3/posts/:pid'); return await api.posts.get(socket, { pid }); diff --git a/src/views/admin/settings/post.tpl b/src/views/admin/settings/post.tpl index 8e7029e906..6c018ec974 100644 --- a/src/views/admin/settings/post.tpl +++ b/src/views/admin/settings/post.tpl @@ -193,6 +193,12 @@
    +
    + +
    diff --git a/src/views/partials/topic/post-preview.tpl b/src/views/partials/topic/post-preview.tpl new file mode 100644 index 0000000000..666313112c --- /dev/null +++ b/src/views/partials/topic/post-preview.tpl @@ -0,0 +1,13 @@ +
    + +
    {post.content}
    +
    From 46789910a81de8d5ecb6ca3fec6cc9f1444808e3 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Mon, 1 Nov 2021 19:09:49 +0000 Subject: [PATCH 330/412] chore(i18n): fallback strings for new resources: nodebb.admin-settings-post --- public/language/ar/admin/settings/post.json | 1 + public/language/bg/admin/settings/post.json | 1 + public/language/bn/admin/settings/post.json | 1 + public/language/cs/admin/settings/post.json | 1 + public/language/da/admin/settings/post.json | 1 + public/language/de/admin/settings/post.json | 1 + public/language/el/admin/settings/post.json | 1 + public/language/en-US/admin/settings/post.json | 1 + public/language/en-x-pirate/admin/settings/post.json | 1 + public/language/es/admin/settings/post.json | 1 + public/language/et/admin/settings/post.json | 1 + public/language/fa-IR/admin/settings/post.json | 1 + public/language/fi/admin/settings/post.json | 1 + public/language/fr/admin/settings/post.json | 1 + public/language/gl/admin/settings/post.json | 1 + public/language/he/admin/settings/post.json | 1 + public/language/hr/admin/settings/post.json | 1 + public/language/hu/admin/settings/post.json | 1 + public/language/id/admin/settings/post.json | 1 + public/language/it/admin/settings/post.json | 1 + public/language/ja/admin/settings/post.json | 1 + public/language/ko/admin/settings/post.json | 1 + public/language/lt/admin/settings/post.json | 1 + public/language/lv/admin/settings/post.json | 1 + public/language/ms/admin/settings/post.json | 1 + public/language/nb/admin/settings/post.json | 1 + public/language/nl/admin/settings/post.json | 1 + public/language/pl/admin/settings/post.json | 1 + public/language/pt-BR/admin/settings/post.json | 1 + public/language/pt-PT/admin/settings/post.json | 1 + public/language/ro/admin/settings/post.json | 1 + public/language/ru/admin/settings/post.json | 1 + public/language/rw/admin/settings/post.json | 1 + public/language/sc/admin/settings/post.json | 1 + public/language/sk/admin/settings/post.json | 1 + public/language/sl/admin/settings/post.json | 1 + public/language/sr/admin/settings/post.json | 1 + public/language/sv/admin/settings/post.json | 1 + public/language/th/admin/settings/post.json | 1 + public/language/tr/admin/settings/post.json | 1 + public/language/uk/admin/settings/post.json | 1 + public/language/vi/admin/settings/post.json | 1 + public/language/zh-CN/admin/settings/post.json | 1 + public/language/zh-TW/admin/settings/post.json | 1 + 44 files changed, 44 insertions(+) diff --git a/public/language/ar/admin/settings/post.json b/public/language/ar/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/ar/admin/settings/post.json +++ b/public/language/ar/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/bg/admin/settings/post.json b/public/language/bg/admin/settings/post.json index 4f41a2cd57..6c80b214c2 100644 --- a/public/language/bg/admin/settings/post.json +++ b/public/language/bg/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Последната – Показване на последната публикация, или първоначалната такава, ако няма отговори.", "teaser.last-reply": "Последната – Показване на последния отговор, или „Няма отговори“, ако все още няма такива.", "teaser.first": "Първата", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Настройки за непрочетените", "unread.cutoff": "Възраст на публикациите, след която те не се показват в непрочетените (в брой дни)", "unread.min-track-last": "Минимален брой публикации в темата, след което да започва следене на последно прочетената", diff --git a/public/language/bn/admin/settings/post.json b/public/language/bn/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/bn/admin/settings/post.json +++ b/public/language/bn/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/cs/admin/settings/post.json b/public/language/cs/admin/settings/post.json index a76f6b446f..eb89abb569 100644 --- a/public/language/cs/admin/settings/post.json +++ b/public/language/cs/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Poslední – zobrazení posledního příspěvku, včetně hlavního příspěvku, nejsou-li odpovědi", "teaser.last-reply": "Poslední – zobrazení poslední odpovědi, nebo nejsou-li žádné odpovědi textu „Bez odpovědi”", "teaser.first": "První", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Nastavení nepřečtených", "unread.cutoff": "Dny ukončení nepřečtených", "unread.min-track-last": "Minimální počet příspěvků v tématu před posledním čtením", diff --git a/public/language/da/admin/settings/post.json b/public/language/da/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/da/admin/settings/post.json +++ b/public/language/da/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/de/admin/settings/post.json b/public/language/de/admin/settings/post.json index 09f5c41b56..9aa327bad0 100644 --- a/public/language/de/admin/settings/post.json +++ b/public/language/de/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Letzter - Den neuesten Beitrag anzeigen, den originalen Beitrag innbegriffen, wenn es keine Antworten gibt", "teaser.last-reply": "Letzter - Den neuesten Beitrag oder einen \"Keine Antworten\" Platzhalter, wenn es keine Antworten gibt anzeigen", "teaser.first": "Erster", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Ungelesen-Einstellungen", "unread.cutoff": "Ungelesen-Limit (in Tagen)", "unread.min-track-last": "Minimale Anzahl an Beiträgen pro Thema bevor die letzte Sichtung mitgeschrieben wird", diff --git a/public/language/el/admin/settings/post.json b/public/language/el/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/el/admin/settings/post.json +++ b/public/language/el/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/en-US/admin/settings/post.json b/public/language/en-US/admin/settings/post.json index 05656c9fba..b4d89f389a 100644 --- a/public/language/en-US/admin/settings/post.json +++ b/public/language/en-US/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/en-x-pirate/admin/settings/post.json b/public/language/en-x-pirate/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/en-x-pirate/admin/settings/post.json +++ b/public/language/en-x-pirate/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/es/admin/settings/post.json b/public/language/es/admin/settings/post.json index 72e094800d..eec90ff156 100644 --- a/public/language/es/admin/settings/post.json +++ b/public/language/es/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Último – Muestra la última entrada, incluyendo la entrada original, si no hay respuestas.", "teaser.last-reply": "Última – Muestra la última respuesta, o un texto \"No hay respuestas\" si no hay respuestas.", "teaser.first": "Primera", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Configuraciones sin leer", "unread.cutoff": "Días límite sin leer", "unread.min-track-last": "Entradas mínimas en un tema antes de indicar la última leída.", diff --git a/public/language/et/admin/settings/post.json b/public/language/et/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/et/admin/settings/post.json +++ b/public/language/et/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/fa-IR/admin/settings/post.json b/public/language/fa-IR/admin/settings/post.json index 57fd21e92f..d07c92aa9d 100644 --- a/public/language/fa-IR/admin/settings/post.json +++ b/public/language/fa-IR/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/fi/admin/settings/post.json b/public/language/fi/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/fi/admin/settings/post.json +++ b/public/language/fi/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/fr/admin/settings/post.json b/public/language/fr/admin/settings/post.json index 8c033dcd9e..96ef48543c 100644 --- a/public/language/fr/admin/settings/post.json +++ b/public/language/fr/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Dernier – Affiche le dernier message, ou celui d'origine, si il n'y a pas de réponse", "teaser.last-reply": "Dernier – Affiche le dernier message, ou \"Aucune réponse\" si il n'y a pas de réponse", "teaser.first": "Premier", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Paramètres des messages non lus", "unread.cutoff": "Nombre de jours pour les messages non-lus", "unread.min-track-last": "Nombre minimum de messages dans le sujet avant de garder en mémoire le dernier message lu", diff --git a/public/language/gl/admin/settings/post.json b/public/language/gl/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/gl/admin/settings/post.json +++ b/public/language/gl/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/he/admin/settings/post.json b/public/language/he/admin/settings/post.json index f2f1611796..a3c9ad12a9 100644 --- a/public/language/he/admin/settings/post.json +++ b/public/language/he/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – הצג את הפוסט האחרון, כולל הפוסט המקורי, אם אין תגובות", "teaser.last-reply": "Last – הצג את התשובה האחרונה, או ציין \"ללא תשובות\" אם אין תשובות", "teaser.first": "ראשון", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "הגדרות \"שלא נקראו\"", "unread.cutoff": "ימי ניתוק שלא נקראו", "unread.min-track-last": "פוסטים מינימליים בנושא לפני מעקב אחר קריאה אחרונה", diff --git a/public/language/hr/admin/settings/post.json b/public/language/hr/admin/settings/post.json index b32357dc51..21e8c03071 100644 --- a/public/language/hr/admin/settings/post.json +++ b/public/language/hr/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "Prvi", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Nepročitane postavke", "unread.cutoff": "Nepročitano dani prekinutosti", "unread.min-track-last": "Minimalni broj objava u temi prije praćenja zadnje pročitanog", diff --git a/public/language/hu/admin/settings/post.json b/public/language/hu/admin/settings/post.json index 2bae9b654e..0bdf3d228b 100644 --- a/public/language/hu/admin/settings/post.json +++ b/public/language/hu/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Utolsó – Utolsó hozzászólás megjelenítése, az eredeti hozzászólást is beleértve, ha nincsenek válaszok", "teaser.last-reply": "Utolsó – Utolsó válasz vagy, ha nincsenek válaszok, akkor \"Nincs válasz\" szöveg megjelenítése", "teaser.first": "Első", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Olvasatlansági beállítások", "unread.cutoff": "Hány napig legyen olvasatlan egy hozzászólás", "unread.min-track-last": "Hozzászólások minimális száma egy témakörben, mielőtt a legutóbbi olvasás követése elkezdődik", diff --git a/public/language/id/admin/settings/post.json b/public/language/id/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/id/admin/settings/post.json +++ b/public/language/id/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/it/admin/settings/post.json b/public/language/it/admin/settings/post.json index 5cbea6601b..0513f2fdfe 100644 --- a/public/language/it/admin/settings/post.json +++ b/public/language/it/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Ultimo – Mostra l'ultimo post, incluso il post originale, se non ci sono risposte", "teaser.last-reply": "Ultimo – Mostra l'ultima risposta o un segnaposto \"Nessuna risposta\" se non risposto", "teaser.first": "Primo", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Impostazioni non Lette", "unread.cutoff": "Giorni di interruzione non letti", "unread.min-track-last": "Post minimi nell'argomento prima del monitoraggio dell'ultima lettura", diff --git a/public/language/ja/admin/settings/post.json b/public/language/ja/admin/settings/post.json index 43cd02324a..8c0502c8d2 100644 --- a/public/language/ja/admin/settings/post.json +++ b/public/language/ja/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "最後&ndash;返信がない場合は、元の投稿を含む最新の投稿を表示", "teaser.last-reply": "最後&ndash;最新の返信を表示するか、返信がない場合は「返信なし」のプレースホルダを表示する", "teaser.first": "最初", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "未読の設定", "unread.cutoff": "未読のカットオフ日", "unread.min-track-last": "最後に読み込みを行う前に追跡するスレッドの最小投稿数", diff --git a/public/language/ko/admin/settings/post.json b/public/language/ko/admin/settings/post.json index ef7b8ab1c6..a2ea9e3e67 100644 --- a/public/language/ko/admin/settings/post.json +++ b/public/language/ko/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "최근 - 최근 작성된 포스트를 보여주고 답글이 없을 경우 포스트 본문 보여주기", "teaser.last-reply": "최근 - 최근 작성된 답글을 보여주고 답글이 없을 경우 \"답글 없음\" 표시", "teaser.first": "첫 글", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "읽지 않음 목록 설정", "unread.cutoff": "읽지 않음 표시 기간", "unread.min-track-last": "마지막으로 읽은 글 추적 기능을 사용할 최소 글 수", diff --git a/public/language/lt/admin/settings/post.json b/public/language/lt/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/lt/admin/settings/post.json +++ b/public/language/lt/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/lv/admin/settings/post.json b/public/language/lv/admin/settings/post.json index 51c48dc131..a6dfd4826c 100644 --- a/public/language/lv/admin/settings/post.json +++ b/public/language/lv/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Pēdējo – rādīt jaunāko rakstu, ieskaitot sākotnējo rakstu, ja atbildes nav", "teaser.last-reply": "Pēdējo – rādīt jaunāko atbildi, vai \"Nav atbildes\" tekstu, ja atbildes nav", "teaser.first": "Pirmais", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Nelasītie raksti", "unread.cutoff": "Nelasīto rakstu vecumu robeža", "unread.min-track-last": "Minimālais rakstu skaits tematā pirms izseko pēdējo lasīto", diff --git a/public/language/ms/admin/settings/post.json b/public/language/ms/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/ms/admin/settings/post.json +++ b/public/language/ms/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/nb/admin/settings/post.json b/public/language/nb/admin/settings/post.json index 30a0e25fed..5e2ca5e30a 100644 --- a/public/language/nb/admin/settings/post.json +++ b/public/language/nb/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum antall innlegg i tråd før registrering av sist lest", diff --git a/public/language/nl/admin/settings/post.json b/public/language/nl/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/nl/admin/settings/post.json +++ b/public/language/nl/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/pl/admin/settings/post.json b/public/language/pl/admin/settings/post.json index 7659b24546..9374e26e45 100644 --- a/public/language/pl/admin/settings/post.json +++ b/public/language/pl/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Ostatni – Pokaż ostatni post, włączając pierwszy post, w razie braku odpowiedzi", "teaser.last-reply": "Ostatni – Pokaż ostatnią odpowiedź lub komunikat „Brak odpowiedzi” w razie ich braku", "teaser.first": "Pierwszy", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Ustawienia nieprzeczytanych", "unread.cutoff": "Dni do odcięcia nieprzeczytanych ", "unread.min-track-last": "Minimalna liczba postów w temacie przed śledzeniem ostatnio przeczytanego", diff --git a/public/language/pt-BR/admin/settings/post.json b/public/language/pt-BR/admin/settings/post.json index 6bfc361519..2f9be57f91 100644 --- a/public/language/pt-BR/admin/settings/post.json +++ b/public/language/pt-BR/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Último – Exibir o último post, incluindo o post original, se não houver respostas", "teaser.last-reply": "Último – Exibir a última resposta, ou um marcador \"Sem respostas\" se não houver respostas", "teaser.first": "Primeiro", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Configurações de Não-Lidos", "unread.cutoff": "Data de corte de não-lidos", "unread.min-track-last": "Mínimo de posts no tópico antes de rastrear o último lido", diff --git a/public/language/pt-PT/admin/settings/post.json b/public/language/pt-PT/admin/settings/post.json index 7e04a1cf14..df1b464869 100644 --- a/public/language/pt-PT/admin/settings/post.json +++ b/public/language/pt-PT/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/ro/admin/settings/post.json b/public/language/ro/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/ro/admin/settings/post.json +++ b/public/language/ro/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/ru/admin/settings/post.json b/public/language/ru/admin/settings/post.json index 86f7ee90a0..a3ebd45ffc 100644 --- a/public/language/ru/admin/settings/post.json +++ b/public/language/ru/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Последнее – показать последнее сообщение в теме (первое, если ответов нет).", "teaser.last-reply": "Последнее – показать последнее сообщение или пометку «Ответов нет»", "teaser.first": "Первое сообщение", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Настройка списка непрочитанных тем", "unread.cutoff": "Порог отсечки (в днях)", "unread.min-track-last": "Минимальное кол-во сообщений в теме, чтобы начать отслеживать непрочитанные ответы", diff --git a/public/language/rw/admin/settings/post.json b/public/language/rw/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/rw/admin/settings/post.json +++ b/public/language/rw/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/sc/admin/settings/post.json b/public/language/sc/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/sc/admin/settings/post.json +++ b/public/language/sc/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/sk/admin/settings/post.json b/public/language/sk/admin/settings/post.json index 8ebf0cc3d1..8c4f8419f0 100644 --- a/public/language/sk/admin/settings/post.json +++ b/public/language/sk/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Posledný - zobrazenie posledného príspevku, vrátane hlavného príspevku, ak nie sú odpovede", "teaser.last-reply": "Posledný - zobrazenie poslednej odpovede, alebo ak nie sú žiadne odpovede textu „Bez odpovede”", "teaser.first": "Prvý", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Nastavenia neprečítaných", "unread.cutoff": "Dni ukončenia neprečítaných", "unread.min-track-last": "Minimálny počet príspevkov v téme pred posledným prečítaním", diff --git a/public/language/sl/admin/settings/post.json b/public/language/sl/admin/settings/post.json index 424104587e..a0ff22173d 100644 --- a/public/language/sl/admin/settings/post.json +++ b/public/language/sl/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Zadnja – Prikaži najnovejšo objavo, vključno z izvirno, če ni odgovorov", "teaser.last-reply": "Zadnja – Prikaži najnovejši odgovor ali \"Ni odgovorov\", če ni odgovorov", "teaser.first": "Prvi", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Neprebrane nastavitve", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Najmanjše število objav v temi pred sledenjem zadnjem branju", diff --git a/public/language/sr/admin/settings/post.json b/public/language/sr/admin/settings/post.json index c1a2a7003b..beba2775b7 100644 --- a/public/language/sr/admin/settings/post.json +++ b/public/language/sr/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Poslednji &ndashč Pokazuje poslednji post, uključujući originalni post, ako nema odgovora", "teaser.last-reply": "Poslednji &ndashč Pokaži najnoviji odgovor, ili ako \"Nema odgovora\" placeholder ako nema odgovora", "teaser.first": "Prvi", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Nepročitana podešavanja", "unread.cutoff": "Nepročitano tokom prekinutih dana", "unread.min-track-last": "Minimum postova u temi, pre praćenja poslednjeg pročitanog", diff --git a/public/language/sv/admin/settings/post.json b/public/language/sv/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/sv/admin/settings/post.json +++ b/public/language/sv/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/th/admin/settings/post.json b/public/language/th/admin/settings/post.json index 00baa56fc1..ab8245738c 100644 --- a/public/language/th/admin/settings/post.json +++ b/public/language/th/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Last – Show the latest post, including the original post, if no replies", "teaser.last-reply": "Last – Show the latest reply, or a \"No replies\" placeholder if no replies", "teaser.first": "First", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", diff --git a/public/language/tr/admin/settings/post.json b/public/language/tr/admin/settings/post.json index 8eb9aba208..8428df7f38 100644 --- a/public/language/tr/admin/settings/post.json +++ b/public/language/tr/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Son – cevap yoksa orijinal gönderi de dahil olmak üzere en son gönderiyi gösterir.", "teaser.last-reply": "Son – cevap yoksa en son yanıtı veya \"Yanıt yok\" yertutucusunu gösterir.", "teaser.first": "İlk", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Okunmamış Ayarları", "unread.cutoff": "Okunmamış gün sınırı", "unread.min-track-last": "Son okumayı takip etmeden önce konuya yapılan asgari gönderim", diff --git a/public/language/uk/admin/settings/post.json b/public/language/uk/admin/settings/post.json index 5219e9aded..ba23e93c33 100644 --- a/public/language/uk/admin/settings/post.json +++ b/public/language/uk/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Останній — показувати останній пост або перший, якщо немає відповідей", "teaser.last-reply": "Останній — показувати останній пост або \"Немає відповідей\", якщо немає відповідей", "teaser.first": "Перший", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Налаштування непрочитаних", "unread.cutoff": "За скільки днів показувати непрочитані", "unread.min-track-last": "Мінімальна кількість постів у темі перш ніж відслідковувати останні прочитані", diff --git a/public/language/vi/admin/settings/post.json b/public/language/vi/admin/settings/post.json index 1db0f903f1..983c9f0902 100644 --- a/public/language/vi/admin/settings/post.json +++ b/public/language/vi/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "Gần đây – Hiển thị bài đăng mới nhất, bao gồm cả bài gốc, nếu không có câu trả lời", "teaser.last-reply": "Cuối cùng - Hiển thị câu trả lời mới nhất hoặc trình giữ chỗ \"Không trả lời\" nếu không có câu trả lời", "teaser.first": "Đầu tiên", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "Cài Đặt Chưa Đọc", "unread.cutoff": "Số ngày giới hạn chưa đọc", "unread.min-track-last": "Số bài viết tối thiểu trong chủ đề trước khi theo dõi lần đọc cuối cùng", diff --git a/public/language/zh-CN/admin/settings/post.json b/public/language/zh-CN/admin/settings/post.json index 7dc59bb94b..2d66c6b6ac 100644 --- a/public/language/zh-CN/admin/settings/post.json +++ b/public/language/zh-CN/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "最后– 显示最新的帖子,包括原帖,如果没有回复", "teaser.last-reply": "最后– 显示最新回复,如果没有回复,则显示“无回复”占位符", "teaser.first": "第一", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "未读设置", "unread.cutoff": "未读截止时间(天)", "unread.min-track-last": "跟踪最后阅读之前的主题最小帖子", diff --git a/public/language/zh-TW/admin/settings/post.json b/public/language/zh-TW/admin/settings/post.json index 607923bae4..057bfe0e6b 100644 --- a/public/language/zh-TW/admin/settings/post.json +++ b/public/language/zh-TW/admin/settings/post.json @@ -40,6 +40,7 @@ "teaser.last-post": "最後– 顯示最新的貼文,包括原帖,如果沒有回覆", "teaser.last-reply": "最後– 顯示最新回覆,如果沒有回覆,則顯示“無回覆”佔位符", "teaser.first": "第一", + "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", "unread": "未讀設定", "unread.cutoff": "未讀截止時間(天)", "unread.min-track-last": "跟蹤最後閱讀之前的主題最小貼文", From 5a0efd2d4222572aabb9760c5c87585067f06292 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 1 Nov 2021 15:30:36 -0400 Subject: [PATCH 331/412] fix: don't use # for previews --- public/src/client/topic.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 6661b43d65..8127967292 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -201,10 +201,11 @@ define('forum/topic', [ } const href = link.attr('href'); + const validHref = href && href !== '#'; const pathname = utils.urlToLocation(href).pathname; $('#post-tooltip').remove(); - const postMatch = pathname && pathname.match(/\/post\/([\d]+)/); - const topicMatch = pathname && pathname.match(/\/topic\/([\d]+)/); + const postMatch = validHref && pathname && pathname.match(/\/post\/([\d]+)/); + const topicMatch = validHref && pathname && pathname.match(/\/topic\/([\d]+)/); if (postMatch) { const pid = postMatch[1]; if (parseInt(link.parents('[component="post"]').attr('data-pid'), 10) === parseInt(pid, 10)) { From 9fbb3b11efb0dfca1255058965c5526902b115cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 1 Nov 2021 18:22:39 -0400 Subject: [PATCH 332/412] perf: only load posts once --- public/src/client/topic.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 8127967292..4f32f70777 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -179,12 +179,14 @@ define('forum/topic', [ return; } let timeoutId = 0; + const postCache = {}; $('[component="topic"]').on('mouseenter', '[component="post"] a, [component="topic/event"] a', async function () { const link = $(this); async function renderPost(pid) { - const postData = await socket.emit('posts.getPostSummaryByPid', { pid: pid }); + const postData = postCache[pid] || await socket.emit('posts.getPostSummaryByPid', { pid: pid }); if (postData) { + postCache[pid] = postData; const tooltip = await app.parseAndTranslate('partials/topic/post-preview', { post: postData }); tooltip.hide().find('.timeago').timeago(); tooltip.appendTo($('body')).fadeIn(300); From b916e42f400dac8aa51670b15e439f87f0eb8939 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 1 Nov 2021 19:36:18 -0400 Subject: [PATCH 333/412] feat: show number of events per type in acp --- src/controllers/admin/events.js | 6 ++++-- src/views/admin/advanced/events.tpl | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/controllers/admin/events.js b/src/controllers/admin/events.js index 1ca791ac16..f077972aca 100644 --- a/src/controllers/admin/events.js +++ b/src/controllers/admin/events.js @@ -20,15 +20,17 @@ eventsController.get = async function (req, res) { const currentFilter = req.query.type || ''; - const [eventCount, eventData] = await Promise.all([ + const [eventCount, eventData, counts] = await Promise.all([ db.sortedSetCount(`events:time${currentFilter ? `:${currentFilter}` : ''}`, from || '-inf', to), events.getEvents(currentFilter, start, stop, from || '-inf', to), + db.sortedSetsCard([''].concat(events.types).map(type => `events:time${type ? `:${type}` : ''}`)), ]); - const types = [''].concat(events.types).map(type => ({ + const types = [''].concat(events.types).map((type, index) => ({ value: type, name: type || 'all', selected: type === currentFilter, + count: counts[index], })); const pageCount = Math.max(1, Math.ceil(eventCount / itemsPerPage)); diff --git a/src/views/admin/advanced/events.tpl b/src/views/admin/advanced/events.tpl index 0456b4bcdd..ccaca544b6 100644 --- a/src/views/admin/advanced/events.tpl +++ b/src/views/admin/advanced/events.tpl @@ -40,7 +40,7 @@ From 81c8d70c51e2b99acbd3789f082e23376fff9c13 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 2 Nov 2021 00:16:25 +0000 Subject: [PATCH 334/412] fix(deps): update dependency validator to v13.7.0 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index b825f4a98f..b8733ff5d0 100644 --- a/install/package.json +++ b/install/package.json @@ -132,7 +132,7 @@ "tinycon": "0.6.8", "toobusy-js": "^0.5.1", "uglify-es": "^3.3.9", - "validator": "13.6.0", + "validator": "13.7.0", "visibilityjs": "2.0.2", "winston": "3.3.3", "xml": "^1.0.1", From 1fce1056c567f81d93bca04c06aca8df98c5f332 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Tue, 2 Nov 2021 09:07:51 +0000 Subject: [PATCH 335/412] Latest translations and fallbacks --- public/language/bg/admin/settings/post.json | 2 +- public/language/he/admin/dashboard.json | 6 +++--- public/language/he/admin/menu.json | 2 +- public/language/he/admin/settings/email.json | 2 +- public/language/he/admin/settings/post.json | 2 +- public/language/he/error.json | 4 ++-- public/language/he/modules.json | 2 +- public/language/he/topic.json | 2 +- public/language/zh-CN/topic.json | 8 ++++---- 9 files changed, 15 insertions(+), 15 deletions(-) diff --git a/public/language/bg/admin/settings/post.json b/public/language/bg/admin/settings/post.json index 6c80b214c2..3844182199 100644 --- a/public/language/bg/admin/settings/post.json +++ b/public/language/bg/admin/settings/post.json @@ -40,7 +40,7 @@ "teaser.last-post": "Последната – Показване на последната публикация, или първоначалната такава, ако няма отговори.", "teaser.last-reply": "Последната – Показване на последния отговор, или „Няма отговори“, ако все още няма такива.", "teaser.first": "Първата", - "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", + "showPostPreviewsOnHover": "Показване на кратък преглед на публикациите при посочване с мишката", "unread": "Настройки за непрочетените", "unread.cutoff": "Възраст на публикациите, след която те не се показват в непрочетените (в брой дни)", "unread.min-track-last": "Минимален брой публикации в темата, след което да започва следене на последно прочетената", diff --git a/public/language/he/admin/dashboard.json b/public/language/he/admin/dashboard.json index 0b9b6e20a6..2f6e8e6ba0 100644 --- a/public/language/he/admin/dashboard.json +++ b/public/language/he/admin/dashboard.json @@ -57,7 +57,7 @@ "active-users.connections": "חיבורים", "guest-registered-users": "Guest vs Registered Users", - "guest": "Guest", + "guest": "אורח", "registered": "רשומים", "user-presence": "נוכחות משתמשים", @@ -68,7 +68,7 @@ "unread": "לא נקראו", "high-presence-topics": "פוסטים עם הכי הרבה נוכחות", - "popular-searches": "Popular Searches", + "popular-searches": "חיפושים פופולריים", "graphs.page-views": "צפיות בדפים", "graphs.page-views-registered": "צפיות בדפים-רשומים", @@ -76,7 +76,7 @@ "graphs.page-views-bot": "צפיות בדפים-בוטים", "graphs.unique-visitors": "מבקרים ייחודיים", "graphs.registered-users": "משתמשים רשומים", - "graphs.guest-users": "Guest Users", + "graphs.guest-users": "משתמשים אורחים", "last-restarted-by": "אותחל לארונה על ידי", "no-users-browsing": "אין גולשים", diff --git a/public/language/he/admin/menu.json b/public/language/he/admin/menu.json index e18bb3012c..95890e7d15 100644 --- a/public/language/he/admin/menu.json +++ b/public/language/he/admin/menu.json @@ -4,7 +4,7 @@ "dashboard/logins": "כניסות", "dashboard/users": "משתמשים", "dashboard/topics": "נושאים", - "dashboard/searches": "Searches", + "dashboard/searches": "חיפושים", "section-general": "כללי", "section-manage": "ניהול", diff --git a/public/language/he/admin/settings/email.json b/public/language/he/admin/settings/email.json index 0c98d497e4..7c1fa4f51b 100644 --- a/public/language/he/admin/settings/email.json +++ b/public/language/he/admin/settings/email.json @@ -37,7 +37,7 @@ "subscriptions.hour": "שעת תקציר", "subscriptions.hour-help": "Please enter a number representing the hour to send scheduled email digests (e.g. 0 for midnight, 17 for 5:00pm). Keep in mind that this is the hour according to the server itself, and may not exactly match your system clock.
    The approximate server time is:
    The next daily digest is scheduled to be sent ", "notifications.remove-images": "הסר תמונות מהודעות דוא\"ל", - "require-email-address": "Require new users to specify an email address", + "require-email-address": "דרוש ממשתמשים חדשים כתובת אימייל", "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", diff --git a/public/language/he/admin/settings/post.json b/public/language/he/admin/settings/post.json index a3c9ad12a9..e2c3681728 100644 --- a/public/language/he/admin/settings/post.json +++ b/public/language/he/admin/settings/post.json @@ -40,7 +40,7 @@ "teaser.last-post": "Last – הצג את הפוסט האחרון, כולל הפוסט המקורי, אם אין תגובות", "teaser.last-reply": "Last – הצג את התשובה האחרונה, או ציין \"ללא תשובות\" אם אין תשובות", "teaser.first": "ראשון", - "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", + "showPostPreviewsOnHover": "הצג תצוגה מקדימה בריחוף על פוסט", "unread": "הגדרות \"שלא נקראו\"", "unread.cutoff": "ימי ניתוק שלא נקראו", "unread.min-track-last": "פוסטים מינימליים בנושא לפני מעקב אחר קריאה אחרונה", diff --git a/public/language/he/error.json b/public/language/he/error.json index cdfa227e31..41575db79d 100644 --- a/public/language/he/error.json +++ b/public/language/he/error.json @@ -34,8 +34,8 @@ "email-invited": "כבר נשלחה הזמנה לדוא\"ל זה", "email-not-confirmed": "פרסום בקטגוריות או בנושאים מסוימים מופעל רק לאחר אישור הדוא\"ל שלך, אנא לחץ כאן כדי לשלוח אימות לדוא\"ל שלך.", "email-not-confirmed-chat": "אין באפשרותך לשוחח עד שהדוא\"ל שלך יאושר, אנא לחץ כאן כדי לאשר את הדוא\"ל שלך.", - "email-not-confirmed-email-sent": "Your email has not been confirmed yet, please check your inbox for the confirmation email. You may not be able to post in some categories or chat until your email is confirmed.", - "no-email-to-confirm": "Your account does not have an email set. An email is necessary for account recovery, and may be necessary for chatting and posting in some categories. Please click here to enter an email.", + "email-not-confirmed-email-sent": "הדוא\"ל שלך עדין לא אושר. אנא בדוק בתיבת הדואר בנוגע לאישור הדוא\"ל שנשלח לך על ידינו. לא תוכל לכתוב פוסטים ולהשתמש בצ'אט לפני אימות הדוא\"ל שלך.", + "no-email-to-confirm": "בחשבונך לא הוגדר דוא\"ל. כתובת דוא\"ל נחוץ לשחזור חשבון. אנא לחץ כאן כדי להכניס דוא\"ל.", "user-doesnt-have-email": "למשתמש \"%1\" לא הוגדר כתובת דוא\"ל.", "email-confirm-failed": "לא הצלחנו לאשר את הדוא\"ל שלך, תנסה שוב אחר כך", "confirm-email-already-sent": "דוא\"ל האישור כבר נשלח, אנא המתן %1 דקות כדי לשלוח דוא\"ל נוסף.", diff --git a/public/language/he/modules.json b/public/language/he/modules.json index 5ad16e23df..ec27ff0fcd 100644 --- a/public/language/he/modules.json +++ b/public/language/he/modules.json @@ -54,7 +54,7 @@ "composer.formatting.strikethrough": "קו פוסל", "composer.formatting.code": "קוד", "composer.formatting.link": "לינק", - "composer.formatting.picture": "Image Link", + "composer.formatting.picture": "קישור תמונה", "composer.upload-picture": "העלה תמונה", "composer.upload-file": "העלה קובץ", "composer.zen_mode": "מסך מלא", diff --git a/public/language/he/topic.json b/public/language/he/topic.json index fecfaa678a..5eb30f0cb8 100644 --- a/public/language/he/topic.json +++ b/public/language/he/topic.json @@ -139,7 +139,7 @@ "composer.handle_placeholder": "הזן את שמך / כינוי שלך כאן", "composer.discard": "ביטול", "composer.submit": "שלח", - "composer.additional-options": "Additional Options", + "composer.additional-options": "אפשרויות נוספות", "composer.schedule": "תזמן", "composer.replying_to": "מגיב ל%1", "composer.new_topic": "נושא חדש", diff --git a/public/language/zh-CN/topic.json b/public/language/zh-CN/topic.json index 970b7f8155..9d8a28c992 100644 --- a/public/language/zh-CN/topic.json +++ b/public/language/zh-CN/topic.json @@ -20,8 +20,8 @@ "login-to-view": "🔒登录查看", "edit": "编辑", "delete": "删除", - "delete-event": "Delete Event", - "delete-event-confirm": "Are you sure you want to delete this event?", + "delete-event": "删除元素", + "delete-event-confirm": "您确定要删除此元素吗?", "purge": "清除", "restore": "恢复", "move": "移动", @@ -39,8 +39,8 @@ "copy-ip": "复制IP", "ban-ip": "封禁IP", "view-history": "编辑历史", - "locked-by": "Locked by", - "unlocked-by": "Unlocked by", + "locked-by": "锁定自", + "unlocked-by": "解锁自", "pinned-by": "Pinned by", "unpinned-by": "Unpinned by", "deleted-by": "Deleted by", From dc78125aa67c759fe1c2ebe6225315c336dd1cb7 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Mon, 1 Nov 2021 09:44:54 +0000 Subject: [PATCH 336/412] chore(deps): update commitlint monorepo to v14 --- install/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index b8733ff5d0..200e346265 100644 --- a/install/package.json +++ b/install/package.json @@ -142,8 +142,8 @@ }, "devDependencies": { "@apidevtools/swagger-parser": "10.0.3", - "@commitlint/cli": "13.2.1", - "@commitlint/config-angular": "13.2.0", + "@commitlint/cli": "14.1.0", + "@commitlint/config-angular": "14.1.0", "coveralls": "3.1.1", "eslint": "7.32.0", "eslint-config-nodebb": "0.0.3", From 8a88295d04aed5dbcac99dcaf4b4ca282f7b49ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 2 Nov 2021 20:05:17 -0400 Subject: [PATCH 337/412] fix: don't highlight external nav items --- public/src/app.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index bacbc2309d..1cf4471fb5 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -285,8 +285,8 @@ app.cacheBuster = null; .removeClass('active') .find('a') .filter(function (i, x) { - return window.location.pathname === x.pathname || - window.location.pathname.startsWith(x.pathname + '/'); + return window.location.hostname === x.hostname && (window.location.pathname === x.pathname || + window.location.pathname.startsWith(x.pathname + '/')); }) .parent() .addClass('active'); From 3e4d477e481f6e23edd52a9392ea43374e4de907 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 3 Nov 2021 00:09:30 -0400 Subject: [PATCH 338/412] chore: up mentions --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 200e346265..05c0309d22 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "2.14.1", + "nodebb-plugin-mentions": "2.15.0", "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", From ddeeee7f1ad2a0232d2c5296d417457bae4aa0ff Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 3 Nov 2021 09:07:30 +0000 Subject: [PATCH 339/412] Latest translations and fallbacks --- public/language/de/admin/advanced/events.json | 2 +- public/language/de/admin/advanced/logs.json | 8 ++++---- public/language/de/admin/manage/digest.json | 4 ++-- public/language/it/admin/settings/post.json | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/public/language/de/admin/advanced/events.json b/public/language/de/admin/advanced/events.json index 8b2cc6bf9a..9f87f04efa 100644 --- a/public/language/de/admin/advanced/events.json +++ b/public/language/de/admin/advanced/events.json @@ -3,7 +3,7 @@ "no-events": "Es gibt keine Ereignisse", "control-panel": "Ereignis-Steuerung", "delete-events": "Ereignisse löschen", - "confirm-delete-all-events": "Are you sure you want to delete all logged events?", + "confirm-delete-all-events": "Bist du sicher, dass du alle gespeicherten Events löschen möchtest?", "filters": "Filter", "filters-apply": "Filter anwenden", "filter-type": "Ereignistyp", diff --git a/public/language/de/admin/advanced/logs.json b/public/language/de/admin/advanced/logs.json index 7399c68b46..e0bce077ae 100644 --- a/public/language/de/admin/advanced/logs.json +++ b/public/language/de/admin/advanced/logs.json @@ -1,7 +1,7 @@ { - "logs": "Protokoll", + "logs": "Protokolle", "control-panel": "Protokoll Steuerung", - "reload": "Protokoll neu laden", - "clear": "Protokoll leeren", - "clear-success": "Protokoll geleert" + "reload": "Protokolle neu laden", + "clear": "Protokolle löschen", + "clear-success": "Protokolle gelöscht" } \ No newline at end of file diff --git a/public/language/de/admin/manage/digest.json b/public/language/de/admin/manage/digest.json index 07e7a5e321..2f1212d11f 100644 --- a/public/language/de/admin/manage/digest.json +++ b/public/language/de/admin/manage/digest.json @@ -5,8 +5,8 @@ "user": "Benutzer", "subscription": "Subscription Type", - "last-delivery": "Last successful delivery", - "default": "System default", + "last-delivery": "Letzte erfolgreiche Zustellung", + "default": "System Standard", "default-help": "System default means the user has not explicitly overridden the global forum setting for digests, which is currently: "%1"", "resend": "Resend Digest", "resend-all-confirm": "Are you sure you wish to manually execute this digest run?", diff --git a/public/language/it/admin/settings/post.json b/public/language/it/admin/settings/post.json index 0513f2fdfe..74c8a44199 100644 --- a/public/language/it/admin/settings/post.json +++ b/public/language/it/admin/settings/post.json @@ -40,7 +40,7 @@ "teaser.last-post": "Ultimo – Mostra l'ultimo post, incluso il post originale, se non ci sono risposte", "teaser.last-reply": "Ultimo – Mostra l'ultima risposta o un segnaposto \"Nessuna risposta\" se non risposto", "teaser.first": "Primo", - "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", + "showPostPreviewsOnHover": "Mostra un'anteprima dei post quando il mouse ci passa sopra", "unread": "Impostazioni non Lette", "unread.cutoff": "Giorni di interruzione non letti", "unread.min-track-last": "Post minimi nell'argomento prima del monitoraggio dell'ultima lettura", From 0f8a68c0457388bdeced648bf653360e457412e7 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Wed, 3 Nov 2021 09:13:20 +0000 Subject: [PATCH 340/412] fix(deps): update dependency nodebb-plugin-mentions to v2.15.1 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 05c0309d22..43f5486f7b 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "2.15.0", + "nodebb-plugin-mentions": "2.15.1", "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", From f728abda06b02ef3e27e16844b22fa4a364e23ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 3 Nov 2021 10:52:03 -0400 Subject: [PATCH 341/412] fix: remove tooltip on ajaxify --- public/src/client/topic.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 4f32f70777..478883b62e 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -180,6 +180,10 @@ define('forum/topic', [ } let timeoutId = 0; const postCache = {}; + $(window).one('action:ajaxify.start', function () { + clearTimeout(timeoutId); + $('#post-tooltip').remove(); + }); $('[component="topic"]').on('mouseenter', '[component="post"] a, [component="topic/event"] a', async function () { const link = $(this); From 98b98a113094fde28a07f6f00569dfcc97ae264c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 3 Nov 2021 12:25:58 -0400 Subject: [PATCH 342/412] chore: up mentions --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 43f5486f7b..7f66b2a0a6 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "2.15.1", + "nodebb-plugin-mentions": "2.15.2", "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", From 2e623dd2713aa71daf8d94ac972e0384c9a2e02c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 3 Nov 2021 16:01:32 -0400 Subject: [PATCH 343/412] feat: #9967, allow dropdowns in navigation --- .../language/en-GB/admin/settings/navigation.json | 4 +++- public/src/app.js | 9 ++++++--- src/controllers/admin/settings.js | 3 +++ src/views/admin/settings/navigation.tpl | 13 +++++++++++++ 4 files changed, 25 insertions(+), 4 deletions(-) diff --git a/public/language/en-GB/admin/settings/navigation.json b/public/language/en-GB/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/en-GB/admin/settings/navigation.json +++ b/public/language/en-GB/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/src/app.js b/public/src/app.js index 1cf4471fb5..e6f3e95e1c 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -284,9 +284,12 @@ app.cacheBuster = null; $('#main-nav li') .removeClass('active') .find('a') - .filter(function (i, x) { - return window.location.hostname === x.hostname && (window.location.pathname === x.pathname || - window.location.pathname.startsWith(x.pathname + '/')); + .filter(function (i, a) { + return $(a).attr('href') !== '#' && window.location.hostname === a.hostname && + ( + window.location.pathname === a.pathname || + window.location.pathname.startsWith(a.pathname + '/') + ); }) .parent() .addClass('active'); diff --git a/src/controllers/admin/settings.js b/src/controllers/admin/settings.js index 41166e6d1c..d4abecd479 100644 --- a/src/controllers/admin/settings.js +++ b/src/controllers/admin/settings.js @@ -1,5 +1,7 @@ 'use strict'; +const validator = require('validator'); + const meta = require('../../meta'); const emailer = require('../../emailer'); const notifications = require('../../notifications'); @@ -72,6 +74,7 @@ settingsController.navigation = async function (req, res) { enabled.selected = index === 0; enabled.title = translator.escape(enabled.title); enabled.text = translator.escape(enabled.text); + enabled.dropdownContent = translator.escape(validator.escape(String(enabled.dropdownContent || ''))); enabled.groups = admin.groups.map(group => ({ displayName: group.displayName, selected: enabled.groups.includes(group.name), diff --git a/src/views/admin/settings/navigation.tpl b/src/views/admin/settings/navigation.tpl index 86cff2d1e1..cd406b90ab 100644 --- a/src/views/admin/settings/navigation.tpl +++ b/src/views/admin/settings/navigation.tpl @@ -89,6 +89,19 @@ +
    + +
    +
    +

    + [[admin/settings/navigation:dropdown-placeholder]] +

    + +
    + From 3727e39f874cf73351224b9430c7a874eed89339 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 3 Nov 2021 20:02:19 +0000 Subject: [PATCH 344/412] chore(i18n): fallback strings for new resources: nodebb.admin-settings-navigation --- public/language/ar/admin/settings/navigation.json | 4 +++- public/language/bg/admin/settings/navigation.json | 4 +++- public/language/bn/admin/settings/navigation.json | 4 +++- public/language/cs/admin/settings/navigation.json | 4 +++- public/language/da/admin/settings/navigation.json | 4 +++- public/language/de/admin/settings/navigation.json | 4 +++- public/language/el/admin/settings/navigation.json | 4 +++- public/language/en-US/admin/settings/navigation.json | 4 +++- public/language/en-x-pirate/admin/settings/navigation.json | 4 +++- public/language/es/admin/settings/navigation.json | 4 +++- public/language/et/admin/settings/navigation.json | 4 +++- public/language/fa-IR/admin/settings/navigation.json | 4 +++- public/language/fi/admin/settings/navigation.json | 4 +++- public/language/fr/admin/settings/navigation.json | 4 +++- public/language/gl/admin/settings/navigation.json | 4 +++- public/language/he/admin/settings/navigation.json | 4 +++- public/language/hr/admin/settings/navigation.json | 4 +++- public/language/hu/admin/settings/navigation.json | 4 +++- public/language/id/admin/settings/navigation.json | 4 +++- public/language/it/admin/settings/navigation.json | 4 +++- public/language/ja/admin/settings/navigation.json | 4 +++- public/language/ko/admin/settings/navigation.json | 4 +++- public/language/lt/admin/settings/navigation.json | 4 +++- public/language/lv/admin/settings/navigation.json | 4 +++- public/language/ms/admin/settings/navigation.json | 4 +++- public/language/nb/admin/settings/navigation.json | 4 +++- public/language/nl/admin/settings/navigation.json | 4 +++- public/language/pl/admin/settings/navigation.json | 4 +++- public/language/pt-BR/admin/settings/navigation.json | 4 +++- public/language/pt-PT/admin/settings/navigation.json | 4 +++- public/language/ro/admin/settings/navigation.json | 4 +++- public/language/ru/admin/settings/navigation.json | 4 +++- public/language/rw/admin/settings/navigation.json | 4 +++- public/language/sc/admin/settings/navigation.json | 4 +++- public/language/sk/admin/settings/navigation.json | 4 +++- public/language/sl/admin/settings/navigation.json | 4 +++- public/language/sr/admin/settings/navigation.json | 4 +++- public/language/sv/admin/settings/navigation.json | 4 +++- public/language/th/admin/settings/navigation.json | 4 +++- public/language/tr/admin/settings/navigation.json | 4 +++- public/language/uk/admin/settings/navigation.json | 4 +++- public/language/vi/admin/settings/navigation.json | 4 +++- public/language/zh-CN/admin/settings/navigation.json | 4 +++- public/language/zh-TW/admin/settings/navigation.json | 4 +++- 44 files changed, 132 insertions(+), 44 deletions(-) diff --git a/public/language/ar/admin/settings/navigation.json b/public/language/ar/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/ar/admin/settings/navigation.json +++ b/public/language/ar/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/bg/admin/settings/navigation.json b/public/language/bg/admin/settings/navigation.json index eee7a0e588..5e53ebbcfd 100644 --- a/public/language/bg/admin/settings/navigation.json +++ b/public/language/bg/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Свойства:", "groups": "Групи:", "open-new-window": "Отваряне в нов прозорец", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Изтриване", "btn.disable": "Изключване", @@ -20,4 +22,4 @@ "custom-route": "Персонализиран маршрут", "core": "ядро", "plugin": "добавка" -} \ No newline at end of file +} diff --git a/public/language/bn/admin/settings/navigation.json b/public/language/bn/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/bn/admin/settings/navigation.json +++ b/public/language/bn/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/cs/admin/settings/navigation.json b/public/language/cs/admin/settings/navigation.json index a434257b94..5811c99768 100644 --- a/public/language/cs/admin/settings/navigation.json +++ b/public/language/cs/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Vlastnosti:", "groups": "Skupiny:", "open-new-window": "Otevřít v novém okně", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Odstranit", "btn.disable": "Zakázat", @@ -20,4 +22,4 @@ "custom-route": "Upravit cestu", "core": "jádro", "plugin": "rozšíření" -} \ No newline at end of file +} diff --git a/public/language/da/admin/settings/navigation.json b/public/language/da/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/da/admin/settings/navigation.json +++ b/public/language/da/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/de/admin/settings/navigation.json b/public/language/de/admin/settings/navigation.json index 1bedf15f20..a3809cafeb 100644 --- a/public/language/de/admin/settings/navigation.json +++ b/public/language/de/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Eigenschaften:", "groups": "Gruppen:", "open-new-window": "In neuem Fenster öffnen", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Löschen", "btn.disable": "Deaktivieren", @@ -20,4 +22,4 @@ "custom-route": "Benutzerdefinierter Pfad", "core": "Kern", "plugin": "Plugin" -} \ No newline at end of file +} diff --git a/public/language/el/admin/settings/navigation.json b/public/language/el/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/el/admin/settings/navigation.json +++ b/public/language/el/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/en-US/admin/settings/navigation.json b/public/language/en-US/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/en-US/admin/settings/navigation.json +++ b/public/language/en-US/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/en-x-pirate/admin/settings/navigation.json b/public/language/en-x-pirate/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/en-x-pirate/admin/settings/navigation.json +++ b/public/language/en-x-pirate/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/es/admin/settings/navigation.json b/public/language/es/admin/settings/navigation.json index 22cad76ef8..3b28dd115a 100644 --- a/public/language/es/admin/settings/navigation.json +++ b/public/language/es/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Propiedades:", "groups": "Grupos:", "open-new-window": "Abrir en una ventana nueva", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Borrar", "btn.disable": "Deshabilitar", @@ -20,4 +22,4 @@ "custom-route": "Ruta Personalizada:", "core": "núcleo", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/et/admin/settings/navigation.json b/public/language/et/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/et/admin/settings/navigation.json +++ b/public/language/et/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/fa-IR/admin/settings/navigation.json b/public/language/fa-IR/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/fa-IR/admin/settings/navigation.json +++ b/public/language/fa-IR/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/fi/admin/settings/navigation.json b/public/language/fi/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/fi/admin/settings/navigation.json +++ b/public/language/fi/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/fr/admin/settings/navigation.json b/public/language/fr/admin/settings/navigation.json index 02d6a7fbeb..857177d2b2 100644 --- a/public/language/fr/admin/settings/navigation.json +++ b/public/language/fr/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Propriétés :", "groups": "Groupes:", "open-new-window": "Ouvrir dans une nouvelle fenêtre", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Supprimer", "btn.disable": "Désactiver", @@ -20,4 +22,4 @@ "custom-route": "Route personnalisée", "core": "cœur", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/gl/admin/settings/navigation.json b/public/language/gl/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/gl/admin/settings/navigation.json +++ b/public/language/gl/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/he/admin/settings/navigation.json b/public/language/he/admin/settings/navigation.json index b89a64c2ac..fd4d8d9509 100644 --- a/public/language/he/admin/settings/navigation.json +++ b/public/language/he/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "הרשאות:", "groups": "קבוצות:", "open-new-window": "פתח בחלון חדש", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "מחק", "btn.disable": "השבת", @@ -20,4 +22,4 @@ "custom-route": "נתיב מותאם אישית", "core": "ליבה", "plugin": "תוסף" -} \ No newline at end of file +} diff --git a/public/language/hr/admin/settings/navigation.json b/public/language/hr/admin/settings/navigation.json index 4921e75e6c..00f84662dd 100644 --- a/public/language/hr/admin/settings/navigation.json +++ b/public/language/hr/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Postavke", "groups": "Groups:", "open-new-window": "Otvori u novom prozoru", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Obriši", "btn.disable": "Onemogući", @@ -20,4 +22,4 @@ "custom-route": "Uobičajna putanja", "core": "jezgra", "plugin": "dodatak" -} \ No newline at end of file +} diff --git a/public/language/hu/admin/settings/navigation.json b/public/language/hu/admin/settings/navigation.json index 5c75530a87..704bea5c2a 100644 --- a/public/language/hu/admin/settings/navigation.json +++ b/public/language/hu/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Tulajdonságok:", "groups": "Csoportok:", "open-new-window": "Megnyitás új ablakban", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Törlés", "btn.disable": "Tiltás", @@ -20,4 +22,4 @@ "custom-route": "Egyéni útvonal", "core": "alapvető", "plugin": "beépülő" -} \ No newline at end of file +} diff --git a/public/language/id/admin/settings/navigation.json b/public/language/id/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/id/admin/settings/navigation.json +++ b/public/language/id/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/it/admin/settings/navigation.json b/public/language/it/admin/settings/navigation.json index 04cd16e1a6..77ba9c2f42 100644 --- a/public/language/it/admin/settings/navigation.json +++ b/public/language/it/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Proprietà:", "groups": "Gruppi:", "open-new-window": "Apri in una nuova finestra", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Elimina", "btn.disable": "Disabilita", @@ -20,4 +22,4 @@ "custom-route": "Percorso personalizzato", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/ja/admin/settings/navigation.json b/public/language/ja/admin/settings/navigation.json index f263418193..f3d7c35e87 100644 --- a/public/language/ja/admin/settings/navigation.json +++ b/public/language/ja/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "プロパティ:", "groups": "Groups:", "open-new-window": "新しいウィンドウで開く", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "削除", "btn.disable": "無効", @@ -20,4 +22,4 @@ "custom-route": "カスタムルート", "core": "コア", "plugin": "プラグイン" -} \ No newline at end of file +} diff --git a/public/language/ko/admin/settings/navigation.json b/public/language/ko/admin/settings/navigation.json index c3c613d0f5..6c6f584c78 100644 --- a/public/language/ko/admin/settings/navigation.json +++ b/public/language/ko/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "속성:", "groups": "그룹:", "open-new-window": "새 창에서 열기", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "삭제", "btn.disable": "비활성화", @@ -20,4 +22,4 @@ "custom-route": "사용자 정의 경로", "core": "코어", "plugin": "플러그인" -} \ No newline at end of file +} diff --git a/public/language/lt/admin/settings/navigation.json b/public/language/lt/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/lt/admin/settings/navigation.json +++ b/public/language/lt/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/lv/admin/settings/navigation.json b/public/language/lv/admin/settings/navigation.json index c6908195e0..b4327584a4 100644 --- a/public/language/lv/admin/settings/navigation.json +++ b/public/language/lv/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Īpašības:", "groups": "Grupas:", "open-new-window": "Rādīt jaunā logā", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Izdzēst", "btn.disable": "Atspējot", @@ -20,4 +22,4 @@ "custom-route": "Pielāgotais ceļš", "core": "kodols", "plugin": "spraudnis" -} \ No newline at end of file +} diff --git a/public/language/ms/admin/settings/navigation.json b/public/language/ms/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/ms/admin/settings/navigation.json +++ b/public/language/ms/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/nb/admin/settings/navigation.json b/public/language/nb/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/nb/admin/settings/navigation.json +++ b/public/language/nb/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/nl/admin/settings/navigation.json b/public/language/nl/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/nl/admin/settings/navigation.json +++ b/public/language/nl/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/pl/admin/settings/navigation.json b/public/language/pl/admin/settings/navigation.json index 42a9e7c98c..36c88f8ca5 100644 --- a/public/language/pl/admin/settings/navigation.json +++ b/public/language/pl/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Ustawienia:", "groups": "Grupy:", "open-new-window": "Otwórz w nowym oknie", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Usuń", "btn.disable": "Wyłącz", @@ -20,4 +22,4 @@ "custom-route": "Niestandardowa ścieżka", "core": "system", "plugin": "wtyczka" -} \ No newline at end of file +} diff --git a/public/language/pt-BR/admin/settings/navigation.json b/public/language/pt-BR/admin/settings/navigation.json index 84704c797e..87f2bea84e 100644 --- a/public/language/pt-BR/admin/settings/navigation.json +++ b/public/language/pt-BR/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Propriedades:", "groups": "Grupos:", "open-new-window": "Abrir em uma nova janela", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Deletar", "btn.disable": "Desativar", @@ -20,4 +22,4 @@ "custom-route": "Rota Personalizada", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/pt-PT/admin/settings/navigation.json b/public/language/pt-PT/admin/settings/navigation.json index 8e5ff802f9..ca1e541e23 100644 --- a/public/language/pt-PT/admin/settings/navigation.json +++ b/public/language/pt-PT/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Propriedades:", "groups": "Grupos:", "open-new-window": "Abrir numa nova janela", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Apagar", "btn.disable": "Desativar", @@ -20,4 +22,4 @@ "custom-route": "Caminho Personalizado", "core": "sistema", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/ro/admin/settings/navigation.json b/public/language/ro/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/ro/admin/settings/navigation.json +++ b/public/language/ro/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/ru/admin/settings/navigation.json b/public/language/ru/admin/settings/navigation.json index 4bcef87827..d5ad4c9534 100644 --- a/public/language/ru/admin/settings/navigation.json +++ b/public/language/ru/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Свойства:", "groups": "Группы:", "open-new-window": "Открывать в новом окне", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Удалить", "btn.disable": "Выключить", @@ -20,4 +22,4 @@ "custom-route": "Произвольный маршрут", "core": "ядро", "plugin": "плагин" -} \ No newline at end of file +} diff --git a/public/language/rw/admin/settings/navigation.json b/public/language/rw/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/rw/admin/settings/navigation.json +++ b/public/language/rw/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/sc/admin/settings/navigation.json b/public/language/sc/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/sc/admin/settings/navigation.json +++ b/public/language/sc/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/sk/admin/settings/navigation.json b/public/language/sk/admin/settings/navigation.json index 24125b086b..59aef4df0b 100644 --- a/public/language/sk/admin/settings/navigation.json +++ b/public/language/sk/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Vlastnosti:", "groups": "Groups:", "open-new-window": "Otvoriť v novom okne", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Odstrániť", "btn.disable": "Zakázať", @@ -20,4 +22,4 @@ "custom-route": "Upraviť cestu", "core": "jadro", "plugin": "zásuvný modul" -} \ No newline at end of file +} diff --git a/public/language/sl/admin/settings/navigation.json b/public/language/sl/admin/settings/navigation.json index fc2c5f2946..fdfe4fce31 100644 --- a/public/language/sl/admin/settings/navigation.json +++ b/public/language/sl/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Lastnosti:", "groups": "Skupine", "open-new-window": "Odpri v novem oknu", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Izbriši", "btn.disable": "Onemogoči", @@ -20,4 +22,4 @@ "custom-route": "Pot po meri", "core": "jedro", "plugin": "vtičnik" -} \ No newline at end of file +} diff --git a/public/language/sr/admin/settings/navigation.json b/public/language/sr/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/sr/admin/settings/navigation.json +++ b/public/language/sr/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/sv/admin/settings/navigation.json b/public/language/sv/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/sv/admin/settings/navigation.json +++ b/public/language/sv/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/th/admin/settings/navigation.json b/public/language/th/admin/settings/navigation.json index 13dd01aae7..7baca85096 100644 --- a/public/language/th/admin/settings/navigation.json +++ b/public/language/th/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Properties:", "groups": "Groups:", "open-new-window": "Open in a new window", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Delete", "btn.disable": "Disable", @@ -20,4 +22,4 @@ "custom-route": "Custom Route", "core": "core", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/tr/admin/settings/navigation.json b/public/language/tr/admin/settings/navigation.json index d961c240de..ea0e2794e3 100644 --- a/public/language/tr/admin/settings/navigation.json +++ b/public/language/tr/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Özellikler:", "groups": "Gruplar", "open-new-window": "Yeni pencerede aç", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Sil", "btn.disable": "Etkinsizleştir", @@ -20,4 +22,4 @@ "custom-route": "Özel Yol", "core": "çekirdek", "plugin": "eklenti" -} \ No newline at end of file +} diff --git a/public/language/uk/admin/settings/navigation.json b/public/language/uk/admin/settings/navigation.json index 7e80dd4304..8d6f6fad19 100644 --- a/public/language/uk/admin/settings/navigation.json +++ b/public/language/uk/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Властивості:", "groups": "Groups:", "open-new-window": "Відкривати у новому вікні", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Видалити", "btn.disable": "Вимкнути", @@ -20,4 +22,4 @@ "custom-route": "Користувацький шлях", "core": "ядро", "plugin": "плагін" -} \ No newline at end of file +} diff --git a/public/language/vi/admin/settings/navigation.json b/public/language/vi/admin/settings/navigation.json index 8f47a0d402..9f41b189e4 100644 --- a/public/language/vi/admin/settings/navigation.json +++ b/public/language/vi/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "Thuộc tính:", "groups": "Nhóm:", "open-new-window": "Mở trong một cửa sổ mới", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Xóa", "btn.disable": "Tắt", @@ -20,4 +22,4 @@ "custom-route": "Tùy Chỉnh Liên Kết", "core": "lõi", "plugin": "plugin" -} \ No newline at end of file +} diff --git a/public/language/zh-CN/admin/settings/navigation.json b/public/language/zh-CN/admin/settings/navigation.json index f7f9003ed1..968f8362ba 100644 --- a/public/language/zh-CN/admin/settings/navigation.json +++ b/public/language/zh-CN/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "属性:", "groups": "群组:", "open-new-window": "在新窗口中打开", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "删除", "btn.disable": "禁用", @@ -20,4 +22,4 @@ "custom-route": "自定义路由", "core": "核心", "plugin": "插件" -} \ No newline at end of file +} diff --git a/public/language/zh-TW/admin/settings/navigation.json b/public/language/zh-TW/admin/settings/navigation.json index 15ac71b9a0..de20547ab9 100644 --- a/public/language/zh-TW/admin/settings/navigation.json +++ b/public/language/zh-TW/admin/settings/navigation.json @@ -11,6 +11,8 @@ "properties": "屬性:", "groups": "群組:", "open-new-window": "在新窗口中打開", + "dropdown": "Dropdown", + "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "刪除", "btn.disable": "禁用", @@ -20,4 +22,4 @@ "custom-route": "自訂路徑", "core": "核心", "plugin": "外掛" -} \ No newline at end of file +} From 8fac8d6188fbb06e24c8bb22f1bb2593d04c6181 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 3 Nov 2021 19:02:13 -0400 Subject: [PATCH 345/412] fix(deps): update dependency nodebb-theme-persona to v11.2.21 (#9969) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 7f66b2a0a6..99693772c8 100644 --- a/install/package.json +++ b/install/package.json @@ -93,7 +93,7 @@ "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", - "nodebb-theme-persona": "11.2.20", + "nodebb-theme-persona": "11.2.21", "nodebb-theme-slick": "1.4.14", "nodebb-theme-vanilla": "12.1.8", "nodebb-widget-essentials": "5.0.4", From f59937314b85b42f60f5abd6fef42fe53964b125 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 3 Nov 2021 19:02:29 -0400 Subject: [PATCH 346/412] fix(deps): update dependency mongodb to v4.1.4 (#9968) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 99693772c8..8d4c3f206c 100644 --- a/install/package.json +++ b/install/package.json @@ -78,7 +78,7 @@ "material-design-lite": "^1.3.0", "mime": "^2.5.2", "mkdirp": "^1.0.4", - "mongodb": "4.1.3", + "mongodb": "4.1.4", "morgan": "^1.10.0", "mousetrap": "^1.6.5", "multiparty": "4.2.2", From 0888aae6d2b3f89dc25c379e7fb5a28e542391b9 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 3 Nov 2021 19:02:38 -0400 Subject: [PATCH 347/412] fix(deps): update dependency nodebb-plugin-mentions to v3 (#9966) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 8d4c3f206c..97be036d6e 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "2.15.2", + "nodebb-plugin-mentions": "3.0.0", "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", From b1d6c9ba2998b01401c36c2f4c6f614901877cb0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 3 Nov 2021 19:05:02 -0400 Subject: [PATCH 348/412] chore: up themes --- install/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index 97be036d6e..fa2455cf70 100644 --- a/install/package.json +++ b/install/package.json @@ -94,8 +94,8 @@ "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.2.1", "nodebb-theme-persona": "11.2.21", - "nodebb-theme-slick": "1.4.14", - "nodebb-theme-vanilla": "12.1.8", + "nodebb-theme-slick": "1.4.15", + "nodebb-theme-vanilla": "12.1.9", "nodebb-widget-essentials": "5.0.4", "nodemailer": "^6.5.0", "nprogress": "0.2.0", From 67cb24912253d1a8000ffcdad5673a1d258d68a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 3 Nov 2021 22:47:15 -0400 Subject: [PATCH 349/412] fix: #9972 --- src/posts/uploads.js | 3 ++- test/topics/thumbs.js | 28 +++++++++++++--------------- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/src/posts/uploads.js b/src/posts/uploads.js index 9cc827d6a5..cfab10671b 100644 --- a/src/posts/uploads.js +++ b/src/posts/uploads.js @@ -41,7 +41,8 @@ module.exports = function (Posts) { if (isMainPost) { const tid = await Posts.getPostField(pid, 'tid'); let thumbs = await topics.thumbs.get(tid); - thumbs = thumbs.map(thumb => thumb.url.replace(path.join(nconf.get('relative_path'), nconf.get('upload_url'), 'files/'), '')).filter(path => !validator.isURL(path, { + const replacePath = path.posix.join(nconf.get('relative_path'), nconf.get('upload_url'), 'files/'); + thumbs = thumbs.map(thumb => thumb.url.replace(replacePath, '')).filter(path => !validator.isURL(path, { require_protocol: true, })); uploads.push(...thumbs); diff --git a/test/topics/thumbs.js b/test/topics/thumbs.js index 417d4c55d8..2cdd1d66a9 100644 --- a/test/topics/thumbs.js +++ b/test/topics/thumbs.js @@ -92,7 +92,7 @@ describe('Topic thumbs', () => { require('../../src/cache').del(`topic:${topicObj.topicData.tid}:thumbs`); const thumbs = await topics.thumbs.get(topicObj.topicData.tid); assert.deepStrictEqual(thumbs, [{ - id: 2, + id: topicObj.topicData.tid, name: 'test.png', url: `${nconf.get('relative_path')}${nconf.get('upload_url')}${relativeThumbPaths[0]}`, }]); @@ -102,7 +102,7 @@ describe('Topic thumbs', () => { const thumbs = await topics.thumbs.get([topicObj.topicData.tid, topicObj.topicData.tid + 1]); assert.deepStrictEqual(thumbs, [ [{ - id: 2, + id: topicObj.topicData.tid, name: 'test.png', url: `${nconf.get('relative_path')}${nconf.get('upload_url')}${relativeThumbPaths[0]}`, }], @@ -132,7 +132,7 @@ describe('Topic thumbs', () => { path: relativeThumbPaths[0], }); - const exists = await db.isSortedSetMember(`topic:3:thumbs`, relativeThumbPaths[0]); + const exists = await db.isSortedSetMember(`topic:${tid}:thumbs`, relativeThumbPaths[0]); assert(exists); }); @@ -153,17 +153,17 @@ describe('Topic thumbs', () => { path: relativeThumbPaths[2], }); - const exists = await db.isSortedSetMember(`topic:3:thumbs`, relativeThumbPaths[2]); + const exists = await db.isSortedSetMember(`topic:${tid}:thumbs`, relativeThumbPaths[2]); assert(exists); }); it('should have a score equal to the number of thumbs prior to addition', async () => { - const scores = await db.sortedSetScores('topic:3:thumbs', [relativeThumbPaths[0], relativeThumbPaths[2]]); + const scores = await db.sortedSetScores(`topic:${tid}:thumbs`, [relativeThumbPaths[0], relativeThumbPaths[2]]); assert.deepStrictEqual(scores, [0, 1]); }); it('should update the relevant topic hash with the number of thumbnails', async () => { - const numThumbs = await topics.getTopicField(3, 'numThumbs'); + const numThumbs = await topics.getTopicField(tid, 'numThumbs'); assert.strictEqual(parseInt(numThumbs, 10), 2); }); @@ -173,7 +173,7 @@ describe('Topic thumbs', () => { path: relativeThumbPaths[0], }); - const score = await db.sortedSetScore(`topic:3:thumbs`, relativeThumbPaths[0]); + const score = await db.sortedSetScore(`topic:${tid}:thumbs`, relativeThumbPaths[0]); assert(isFinite(score)); // exists in set assert.strictEqual(score, 2); @@ -186,7 +186,7 @@ describe('Topic thumbs', () => { score: 0, }); - const score = await db.sortedSetScore(`topic:3:thumbs`, relativeThumbPaths[0]); + const score = await db.sortedSetScore(`topic:${tid}:thumbs`, relativeThumbPaths[0]); assert(isFinite(score)); // exists in set assert.strictEqual(score, 0); @@ -202,27 +202,25 @@ describe('Topic thumbs', () => { const uploads = await posts.uploads.list(mainPid); assert(uploads.includes(path.basename(relativeThumbPaths[0]))); }); - }); - describe('.migrate()', () => { it('should combine the thumbs uploaded to a UUID zset and combine it with a topic\'s thumb zset', async () => { - await topics.thumbs.migrate(uuid, 3); + await topics.thumbs.migrate(uuid, tid); - const thumbs = await topics.thumbs.get(3); + const thumbs = await topics.thumbs.get(tid); assert.strictEqual(thumbs.length, 3); assert.deepStrictEqual(thumbs, [ { - id: 3, + id: tid, name: 'test.png', url: `${nconf.get('relative_path')}${nconf.get('upload_url')}${relativeThumbPaths[0]}`, }, { - id: 3, + id: tid, name: 'example.org', url: 'https://example.org', }, { - id: 3, + id: tid, name: 'test2.png', url: `${nconf.get('relative_path')}${nconf.get('upload_url')}${relativeThumbPaths[1]}`, }, From d27c9696e3d90b823172a6c492b40d1c6bba581e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 4 Nov 2021 00:09:14 -0400 Subject: [PATCH 350/412] feat: add node 16 (#9847) * feat: add node 16 * fix: check errors in fork * test: add use-spawn * test: another test * Revert "test: another test" This reverts commit 606efe26fe1decd5d9269d63d5b649441ba2203b. * test: another test * fix: lint * fix: remove spawn-wrap * test: comment out plugin installs * fix: lint * test: uncomment all tests except npm i * fix: lint * test: bring back tests * test: remove leftover override --- .github/workflows/test.yaml | 2 +- src/password.js | 4 ++++ test/package-install.js | 6 ++++-- test/plugins.js | 23 ++++++++++++++++++----- test/socket.io.js | 35 +++++++++++++++++++++++++++++++---- 5 files changed, 58 insertions(+), 12 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 90683cf490..e8b07af4cd 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -21,7 +21,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest] - node: [12, 14] + node: [12, 14, 16] database: [mongo-dev, mongo, redis, postgres] include: # only run coverage once diff --git a/src/password.js b/src/password.js index 727528a3a8..d1b6fc2df5 100644 --- a/src/password.js +++ b/src/password.js @@ -14,6 +14,10 @@ function forkChild(message, callback) { child.on('message', (msg) => { callback(msg.err ? new Error(msg.err) : null, msg.result); }); + child.on('error', (err) => { + console.error(err.stack); + callback(err); + }); child.send(message); } diff --git a/test/package-install.js b/test/package-install.js index 3305c2e532..34d256c9f4 100644 --- a/test/package-install.js +++ b/test/package-install.js @@ -1,6 +1,5 @@ 'use strict'; - const { execSync } = require('child_process'); const path = require('path'); const { readFileSync } = require('fs'); @@ -9,12 +8,14 @@ const assert = require('assert'); describe('Package install', () => { it('should remove non-`nodebb-` modules not specified in `install/package.json`', () => { + const oldValue = process.env.NODE_ENV; + process.env.NODE_ENV = 'development'; const packageFilePath = path.join(__dirname, '../package.json'); // install an extra package // chose dotenv because it's a popular package // and we use nconf instead - execSync('npm install dotenv --save --production'); + execSync('npm install dotenv --save'); // assert it saves in package.json const packageWithExtras = JSON.parse(readFileSync(packageFilePath, 'utf8')); @@ -26,5 +27,6 @@ describe('Package install', () => { // assert it removed the extra package const packageCleaned = JSON.parse(readFileSync(packageFilePath, 'utf8')); assert(!packageCleaned.dependencies.dotenv, 'dependency was not removed'); + process.env.NODE_ENV = oldValue; }); }); diff --git a/test/plugins.js b/test/plugins.js index ae5e403abf..04465896f8 100644 --- a/test/plugins.js +++ b/test/plugins.js @@ -1,7 +1,6 @@ 'use strict'; - -const assert = require('assert'); +const assert = require('assert'); const path = require('path'); const nconf = require('nconf'); const request = require('request'); @@ -47,7 +46,7 @@ describe('Plugins', () => { }); }); - it('should register and fire a filter hook having 3 methods, one returning a promise, one calling the callback and one just returning', async () => { + it('should register and fire a filter hook having 3 methods', async () => { function method1(data, callback) { data.foo += 1; callback(null, data); @@ -214,6 +213,16 @@ describe('Plugins', () => { describe('install/activate/uninstall', () => { let latest; const pluginName = 'nodebb-plugin-imgur'; + const oldValue = process.env.NODE_ENV; + before((done) => { + process.env.NODE_ENV = 'development'; + done(); + }); + after((done) => { + process.env.NODE_ENV = oldValue; + done(); + }); + it('should install a plugin', function (done) { this.timeout(0); plugins.toggleInstall(pluginName, '1.0.16', (err, pluginData) => { @@ -284,7 +293,8 @@ describe('Plugins', () => { }); it('should 404 if resource does not exist', (done) => { - request.get(`${nconf.get('url')}/plugins/nodebb-plugin-dbsearch/dbsearch/templates/admin/plugins/should404.tpl`, (err, res, body) => { + const url = `${nconf.get('url')}/plugins/nodebb-plugin-dbsearch/dbsearch/templates/admin/plugins/should404.tpl`; + request.get(url, (err, res, body) => { assert.ifError(err); assert.equal(res.statusCode, 404); assert(body); @@ -293,7 +303,8 @@ describe('Plugins', () => { }); it('should get resource', (done) => { - request.get(`${nconf.get('url')}/plugins/nodebb-plugin-dbsearch/dbsearch/templates/admin/plugins/dbsearch.tpl`, (err, res, body) => { + const url = `${nconf.get('url')}/plugins/nodebb-plugin-dbsearch/dbsearch/templates/admin/plugins/dbsearch.tpl`; + request.get(url, (err, res, body) => { assert.ifError(err); assert.equal(res.statusCode, 200); assert(body); @@ -302,3 +313,5 @@ describe('Plugins', () => { }); }); }); + + diff --git a/test/socket.io.js b/test/socket.io.js index b707de09a0..fad6591185 100644 --- a/test/socket.io.js +++ b/test/socket.io.js @@ -106,7 +106,12 @@ describe('socket.io', () => { }); it('should post a topic', (done) => { - io.emit('topics.post', { title: 'test topic title', content: 'test topic main post content', uid: adminUid, cid: cid }, (err, result) => { + io.emit('topics.post', { + title: 'test topic title', + content: 'test topic main post content', + uid: adminUid, + cid: cid, + }, (err, result) => { assert.ifError(err); assert.equal(result.user.username, 'admin'); assert.equal(result.category.cid, cid); @@ -473,9 +478,17 @@ describe('socket.io', () => { it('should toggle plugin install', function (done) { this.timeout(0); - socketAdmin.plugins.toggleInstall({ uid: adminUid }, { id: 'nodebb-plugin-location-to-map', version: 'latest' }, (err, data) => { + const oldValue = process.env.NODE_ENV; + process.env.NODE_ENV = 'development'; + socketAdmin.plugins.toggleInstall({ + uid: adminUid, + }, { + id: 'nodebb-plugin-location-to-map', + version: 'latest', + }, (err, data) => { assert.ifError(err); assert.equal(data.name, 'nodebb-plugin-location-to-map'); + process.env.NODE_ENV = oldValue; done(); }); }); @@ -507,8 +520,16 @@ describe('socket.io', () => { it('should upgrade plugin', function (done) { this.timeout(0); - socketAdmin.plugins.upgrade({ uid: adminUid }, { id: 'nodebb-plugin-location-to-map', version: 'latest' }, (err) => { + const oldValue = process.env.NODE_ENV; + process.env.NODE_ENV = 'development'; + socketAdmin.plugins.upgrade({ + uid: adminUid, + }, { + id: 'nodebb-plugin-location-to-map', + version: 'latest', + }, (err) => { assert.ifError(err); + process.env.NODE_ENV = oldValue; done(); }); }); @@ -521,7 +542,13 @@ describe('socket.io', () => { }); it('should error with invalid data', (done) => { - const data = [{ template: 'global', location: 'sidebar', widgets: [{ widget: 'html', data: { html: 'test', title: 'test', container: '' } }] }]; + const data = [ + { + template: 'global', + location: 'sidebar', + widgets: [{ widget: 'html', data: { html: 'test', title: 'test', container: '' } }], + }, + ]; socketAdmin.widgets.set({ uid: adminUid }, data, (err) => { assert.ifError(err); db.getObjectField('widgets:global', 'sidebar', (err, widgetData) => { From fb0588576da09055afb8038be768d39b64772781 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Thu, 4 Nov 2021 09:07:12 +0000 Subject: [PATCH 351/412] Latest translations and fallbacks --- public/language/bg/admin/settings/navigation.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/language/bg/admin/settings/navigation.json b/public/language/bg/admin/settings/navigation.json index 5e53ebbcfd..34dc2112d8 100644 --- a/public/language/bg/admin/settings/navigation.json +++ b/public/language/bg/admin/settings/navigation.json @@ -11,8 +11,8 @@ "properties": "Свойства:", "groups": "Групи:", "open-new-window": "Отваряне в нов прозорец", - "dropdown": "Dropdown", - "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", + "dropdown": "Падащо меню", + "dropdown-placeholder": "Въведете елементите на падащото меню по-долу. Пример:
    <li><a href="https://myforum.com">Връзка 1</a></li>", "btn.delete": "Изтриване", "btn.disable": "Изключване", From 66e7cdac7a61726c80ed5a4311c70b39d570533c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 4 Nov 2021 11:45:06 -0400 Subject: [PATCH 352/412] fix: #9973, ignore if assigning to same parent --- src/categories/update.js | 3 +++ test/categories.js | 20 ++++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/src/categories/update.js b/src/categories/update.js index cdca138635..04650a4c46 100644 --- a/src/categories/update.js +++ b/src/categories/update.js @@ -71,6 +71,9 @@ module.exports = function (Categories) { } const categoryData = await Categories.getCategoryFields(cid, ['parentCid', 'order']); const oldParent = categoryData.parentCid; + if (oldParent === newParent) { + return; + } await Promise.all([ db.sortedSetRemove(`cid:${oldParent}:children`, cid), db.sortedSetAdd(`cid:${newParent}:children`, categoryData.order, cid), diff --git a/test/categories.js b/test/categories.js index d1e5cbf746..e91a51f619 100644 --- a/test/categories.js +++ b/test/categories.js @@ -432,6 +432,26 @@ describe('Categories', () => { }); }); + it('should not remove category from parent if parent is set again to same category', async () => { + const parentCat = await Categories.create({ name: 'parent', description: 'poor parent' }); + const updateData = {}; + updateData[cid] = { + parentCid: parentCat.cid, + }; + await Categories.update(updateData); + let data = await Categories.getCategoryData(cid); + assert.equal(data.parentCid, updateData[cid].parentCid); + let childrenCids = await db.getSortedSetRange(`cid:${parentCat.cid}:children`, 0, -1); + assert(childrenCids.includes(String(cid))); + + // update again to same parent + await Categories.update(updateData); + data = await Categories.getCategoryData(cid); + assert.equal(data.parentCid, updateData[cid].parentCid); + childrenCids = await db.getSortedSetRange(`cid:${parentCat.cid}:children`, 0, -1); + assert(childrenCids.includes(String(cid))); + }); + it('should purge category', (done) => { Categories.create({ name: 'purge me', From 054685265d0b5e625a3e5f751e97940fbbb4fca4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 4 Nov 2021 13:19:37 -0400 Subject: [PATCH 353/412] fix: category load more btn visibility --- public/src/client/category.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/public/src/client/category.js b/public/src/client/category.js index 03d63bae86..da8a6296cf 100644 --- a/public/src/client/category.js +++ b/public/src/client/category.js @@ -107,7 +107,8 @@ define('forum/category', [ app.createUserTooltips(html); ajaxify.data.nextSubCategoryStart += ajaxify.data.subCategoriesPerPage; ajaxify.data.subCategoriesLeft -= data.length; - btn.translateText('[[category:x-more-categories, ' + ajaxify.data.subCategoriesLeft + ']]'); + btn.toggleClass('hidden', ajaxify.data.subCategoriesLeft <= 0) + .translateText('[[category:x-more-categories, ' + ajaxify.data.subCategoriesLeft + ']]'); }); }); return false; From c1cc35a949ec531cdbdb2ab612087a7359925d55 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 4 Nov 2021 14:23:16 -0400 Subject: [PATCH 354/412] refactor: display errors from category drag/drop --- public/src/admin/manage/categories.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/admin/manage/categories.js b/public/src/admin/manage/categories.js index c8a8a10bfd..23c85892a4 100644 --- a/public/src/admin/manage/categories.js +++ b/public/src/admin/manage/categories.js @@ -208,7 +208,7 @@ define('admin/manage/categories', [ } newCategoryId = -1; - api.put('/categories/' + cid, modified[cid]); + api.put('/categories/' + cid, modified[cid]).catch(app.alertError); } } From 9e1d8da643ac39f6d82228b1b78fdfb207108d6b Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Fri, 5 Nov 2021 09:06:51 +0000 Subject: [PATCH 355/412] Latest translations and fallbacks --- public/language/vi/admin/settings/navigation.json | 4 ++-- public/language/vi/admin/settings/post.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/public/language/vi/admin/settings/navigation.json b/public/language/vi/admin/settings/navigation.json index 9f41b189e4..22ce457fb4 100644 --- a/public/language/vi/admin/settings/navigation.json +++ b/public/language/vi/admin/settings/navigation.json @@ -11,8 +11,8 @@ "properties": "Thuộc tính:", "groups": "Nhóm:", "open-new-window": "Mở trong một cửa sổ mới", - "dropdown": "Dropdown", - "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", + "dropdown": "Thả xuống", + "dropdown-placeholder": "Đặt các mục menu thả xuống của bạn bên dưới, tức là:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Xóa", "btn.disable": "Tắt", diff --git a/public/language/vi/admin/settings/post.json b/public/language/vi/admin/settings/post.json index 983c9f0902..db7602bd43 100644 --- a/public/language/vi/admin/settings/post.json +++ b/public/language/vi/admin/settings/post.json @@ -40,7 +40,7 @@ "teaser.last-post": "Gần đây – Hiển thị bài đăng mới nhất, bao gồm cả bài gốc, nếu không có câu trả lời", "teaser.last-reply": "Cuối cùng - Hiển thị câu trả lời mới nhất hoặc trình giữ chỗ \"Không trả lời\" nếu không có câu trả lời", "teaser.first": "Đầu tiên", - "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", + "showPostPreviewsOnHover": "Hiển thị bản xem trước của các bài đăng khi di chuột qua", "unread": "Cài Đặt Chưa Đọc", "unread.cutoff": "Số ngày giới hạn chưa đọc", "unread.min-track-last": "Số bài viết tối thiểu trong chủ đề trước khi theo dõi lần đọc cuối cùng", From 41e02400103073b69da7e127c3feb30ea68831c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 5 Nov 2021 13:20:13 -0400 Subject: [PATCH 356/412] fix: dont show previews on mobile --- public/src/client/topic.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 478883b62e..03bdeb0736 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -175,7 +175,7 @@ define('forum/topic', [ } function addPostsPreviewHandler() { - if (!ajaxify.data.showPostPreviewsOnHover) { + if (!ajaxify.data.showPostPreviewsOnHover || utils.isMobile()) { return; } let timeoutId = 0; From 9bfb6c72814e957164bac12f3845428e2bdad4a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 5 Nov 2021 14:11:03 -0400 Subject: [PATCH 357/412] fix: #9976, handle array or object --- src/search.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/search.js b/src/search.js index 0a0d1f459c..d71430c437 100644 --- a/src/search.js +++ b/src/search.js @@ -45,14 +45,16 @@ async function searchInContent(data) { async function doSearch(type, searchIn) { if (searchIn.includes(data.searchIn)) { - return await plugins.hooks.fire('filter:search.query', { + const result = await plugins.hooks.fire('filter:search.query', { index: type, content: data.query, matchWords: data.matchWords || 'all', cid: searchCids, uid: searchUids, searchData: data, + ids: [], }); + return Array.isArray(result) ? result : result.ids; } return []; } From 28dd31a8e7053449710228df178384eb825e1d49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 5 Nov 2021 14:12:45 -0400 Subject: [PATCH 358/412] fix: #9976 --- src/topics/index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/topics/index.js b/src/topics/index.js index 06a6879c6c..67614927ae 100644 --- a/src/topics/index.js +++ b/src/topics/index.js @@ -319,11 +319,12 @@ Topics.isLocked = async function (tid) { }; Topics.search = async function (tid, term) { - const pids = await plugins.hooks.fire('filter:topic.search', { + const result = await plugins.hooks.fire('filter:topic.search', { tid: tid, term: term, + ids: [], }); - return Array.isArray(pids) ? pids : []; + return Array.isArray(result) ? result : result.ids; }; require('../promisify')(Topics); From 4ac9270a2ab94d80bf02481a5a6e639524c2bed2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 5 Nov 2021 14:25:43 -0400 Subject: [PATCH 359/412] test: increase timeout --- test/messaging.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/messaging.js b/test/messaging.js index fbec60234f..996ad14bdb 100644 --- a/test/messaging.js +++ b/test/messaging.js @@ -408,7 +408,7 @@ describe('Messaging Library', () => { await db.sortedSetAdd('users:online', Date.now() - ((meta.config.onlineCutoff * 60000) + 50000), herpUid); await socketModules.chats.send({ uid: fooUid }, { roomId: roomId, message: 'second chat message **bold** text' }); - await sleep(1500); + await sleep(3000); const data = await User.notifications.get(herpUid); assert(data.unread[0]); const notification = data.unread[0]; From f7295aaad5ede350f707197900e9e29a36f047f6 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Fri, 5 Nov 2021 18:26:55 +0000 Subject: [PATCH 360/412] fix(deps): update dependency nodebb-theme-lavender to v5.3.1 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index fa2455cf70..8a08d5e1ce 100644 --- a/install/package.json +++ b/install/package.json @@ -92,7 +92,7 @@ "nodebb-plugin-mentions": "3.0.0", "nodebb-plugin-spam-be-gone": "0.7.10", "nodebb-rewards-essentials": "0.2.0", - "nodebb-theme-lavender": "5.2.1", + "nodebb-theme-lavender": "5.3.1", "nodebb-theme-persona": "11.2.21", "nodebb-theme-slick": "1.4.15", "nodebb-theme-vanilla": "12.1.9", From 91293ecc6ddcd2a12401d6b31be6088f82edaeb8 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Fri, 5 Nov 2021 18:26:40 +0000 Subject: [PATCH 361/412] fix(deps): update dependency nodebb-plugin-spam-be-gone to v0.7.11 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 8a08d5e1ce..2bfa4d104d 100644 --- a/install/package.json +++ b/install/package.json @@ -90,7 +90,7 @@ "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", "nodebb-plugin-mentions": "3.0.0", - "nodebb-plugin-spam-be-gone": "0.7.10", + "nodebb-plugin-spam-be-gone": "0.7.11", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.3.1", "nodebb-theme-persona": "11.2.21", From 8224a2a930082c7ac17224b3758a24b06f6e9926 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 5 Nov 2021 15:47:36 -0400 Subject: [PATCH 362/412] fix(deps): update dependency nodebb-plugin-mentions to v3.0.1 (#9979) Co-authored-by: Renovate Bot Co-authored-by: Julian Lam --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 2bfa4d104d..7b7eb0efee 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "3.0.0", + "nodebb-plugin-mentions": "3.0.1", "nodebb-plugin-spam-be-gone": "0.7.11", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.3.1", From 7fee0e32722f6a961a32a3abd0bb9a3c2017cf26 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Fri, 5 Nov 2021 19:46:46 +0000 Subject: [PATCH 363/412] fix(deps): update dependency nodebb-plugin-composer-default to v7.0.12 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 7b7eb0efee..ee563a35da 100644 --- a/install/package.json +++ b/install/package.json @@ -84,7 +84,7 @@ "multiparty": "4.2.2", "@nodebb/bootswatch": "3.4.2", "nconf": "^0.11.2", - "nodebb-plugin-composer-default": "7.0.11", + "nodebb-plugin-composer-default": "7.0.12", "nodebb-plugin-dbsearch": "5.0.5", "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", From 3386893b58673fb8d6b04b43638ed6c70fb52842 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 5 Nov 2021 18:14:08 -0400 Subject: [PATCH 364/412] test: dbsearch no longer has staticDir --- test/build.js | 1 - 1 file changed, 1 deletion(-) diff --git a/test/build.js b/test/build.js index 41bc2f24c9..0727bc6d27 100644 --- a/test/build.js +++ b/test/build.js @@ -130,7 +130,6 @@ describe('Build', (done) => { it('should build plugin static dirs', (done) => { build.build(['plugin static dirs'], (err) => { assert.ifError(err); - assert(file.existsSync(path.join(__dirname, '../build/public/plugins/nodebb-plugin-dbsearch/dbsearch'))); done(); }); }); From 4f1ee1fcb14faba6d18986a1c1ed639213840966 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 5 Nov 2021 18:16:36 -0400 Subject: [PATCH 365/412] fix(deps): update dependency nodebb-plugin-dbsearch to v5.1.0 (#9983) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index ee563a35da..a9be5da3fc 100644 --- a/install/package.json +++ b/install/package.json @@ -85,7 +85,7 @@ "@nodebb/bootswatch": "3.4.2", "nconf": "^0.11.2", "nodebb-plugin-composer-default": "7.0.12", - "nodebb-plugin-dbsearch": "5.0.5", + "nodebb-plugin-dbsearch": "5.1.0", "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", From 30cce14204f3f38e897a7f06f20be7fa5c0f7a2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 5 Nov 2021 20:21:19 -0400 Subject: [PATCH 366/412] test: fix tpl test --- test/plugins.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/plugins.js b/test/plugins.js index 04465896f8..1b9864a920 100644 --- a/test/plugins.js +++ b/test/plugins.js @@ -303,7 +303,7 @@ describe('Plugins', () => { }); it('should get resource', (done) => { - const url = `${nconf.get('url')}/plugins/nodebb-plugin-dbsearch/dbsearch/templates/admin/plugins/dbsearch.tpl`; + const url = `${nconf.get('url')}/assets/templates/admin/plugins/dbsearch.tpl`; request.get(url, (err, res, body) => { assert.ifError(err); assert.equal(res.statusCode, 200); From 8a12ac34703661e32784e16a8c90d6fdc18c347e Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Sat, 6 Nov 2021 09:06:33 +0000 Subject: [PATCH 367/412] Latest translations and fallbacks --- public/language/fr/admin/settings/navigation.json | 4 ++-- public/language/fr/admin/settings/post.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/public/language/fr/admin/settings/navigation.json b/public/language/fr/admin/settings/navigation.json index 857177d2b2..1305aed145 100644 --- a/public/language/fr/admin/settings/navigation.json +++ b/public/language/fr/admin/settings/navigation.json @@ -11,8 +11,8 @@ "properties": "Propriétés :", "groups": "Groupes:", "open-new-window": "Ouvrir dans une nouvelle fenêtre", - "dropdown": "Dropdown", - "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", + "dropdown": "Menu déroulant", + "dropdown-placeholder": "Placez vos éléments de menu déroulant ci-dessous, par exemple :
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Supprimer", "btn.disable": "Désactiver", diff --git a/public/language/fr/admin/settings/post.json b/public/language/fr/admin/settings/post.json index 96ef48543c..9a546492b1 100644 --- a/public/language/fr/admin/settings/post.json +++ b/public/language/fr/admin/settings/post.json @@ -40,7 +40,7 @@ "teaser.last-post": "Dernier – Affiche le dernier message, ou celui d'origine, si il n'y a pas de réponse", "teaser.last-reply": "Dernier – Affiche le dernier message, ou \"Aucune réponse\" si il n'y a pas de réponse", "teaser.first": "Premier", - "showPostPreviewsOnHover": "Show a preview of posts when mouse overed", + "showPostPreviewsOnHover": "Afficher un aperçu des messages au survol des liens", "unread": "Paramètres des messages non lus", "unread.cutoff": "Nombre de jours pour les messages non-lus", "unread.min-track-last": "Nombre minimum de messages dans le sujet avant de garder en mémoire le dernier message lu", From 890bf03fcc6905fe1cbe0191a34969b00b360f4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Sat, 6 Nov 2021 21:20:05 -0400 Subject: [PATCH 368/412] refactor: acp only uses 3 modes and a single theme so only copy 7 files to build folder instead of 400+ --- src/meta/js.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/meta/js.js b/src/meta/js.js index 63a7d84126..8e712ccf15 100644 --- a/src/meta/js.js +++ b/src/meta/js.js @@ -89,7 +89,16 @@ JS.scripts = { 'cropper.js': 'node_modules/cropperjs/dist/cropper.min.js', 'jquery-ui': 'node_modules/jquery-ui/ui', 'zxcvbn.js': 'node_modules/zxcvbn/dist/zxcvbn.js', - ace: 'node_modules/ace-builds/src-min', + + // only get ace files required by acp + 'ace/ace.js': 'node_modules/ace-builds/src-min/ace.js', + 'ace/mode-less.js': 'node_modules/ace-builds/src-min/mode-less.js', + 'ace/mode-javascript.js': 'node_modules/ace-builds/src-min/mode-javascript.js', + 'ace/mode-html.js': 'node_modules/ace-builds/src-min/mode-html.js', + 'ace/theme-twilight.js': 'node_modules/ace-builds/src-min/theme-twilight.js', + 'ace/worker-javascript.js': 'node_modules/ace-builds/src-min/worker-javascript.js', + 'ace/worker-html.js': 'node_modules/ace-builds/src-min/worker-html.js', + 'clipboard.js': 'node_modules/clipboard/dist/clipboard.min.js', 'tinycon.js': 'node_modules/tinycon/tinycon.js', 'slideout.js': 'node_modules/slideout/dist/slideout.min.js', From 4b738c8cd36c936a1dbe2bb900c694bf6c5520ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Sat, 6 Nov 2021 22:07:06 -0400 Subject: [PATCH 369/412] refactor: cleanup info, better cpu usage % --- .../en-GB/admin/development/info.json | 6 ++++- src/controllers/admin/info.js | 26 +++++++++++++------ src/views/admin/development/info.tpl | 13 +++++++--- 3 files changed, 33 insertions(+), 12 deletions(-) diff --git a/public/language/en-GB/admin/development/info.json b/public/language/en-GB/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/en-GB/admin/development/info.json +++ b/public/language/en-GB/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/src/controllers/admin/info.js b/src/controllers/admin/info.js index 60558f2ad6..efd126579e 100644 --- a/src/controllers/admin/info.js +++ b/src/controllers/admin/info.js @@ -11,6 +11,8 @@ const rooms = require('../../socket.io/admin/rooms'); const infoController = module.exports; let info = {}; +let previousUsage = process.cpuUsage(); +let usageStartDate = Date.now(); infoController.get = function (req, res) { info = {}; @@ -69,7 +71,7 @@ async function getNodeInfo() { version: process.version, memoryUsage: process.memoryUsage(), uptime: process.uptime(), - cpuUsage: process.cpuUsage(), + cpuUsage: getCpuUsage(), }, os: { hostname: os.hostname(), @@ -88,14 +90,12 @@ async function getNodeInfo() { jobsDisabled: nconf.get('jobsDisabled'), }, }; - data.process.cpuUsage.user /= 1000000; - data.process.cpuUsage.user = data.process.cpuUsage.user.toFixed(2); - data.process.cpuUsage.system /= 1000000; - data.process.cpuUsage.system = data.process.cpuUsage.system.toFixed(2); - data.process.memoryUsage.humanReadable = (data.process.memoryUsage.rss / (1024 * 1024)).toFixed(2); + + data.process.memoryUsage.humanReadable = (data.process.memoryUsage.rss / (1024 * 1024 * 1024)).toFixed(3); data.process.uptimeHumanReadable = humanReadableUptime(data.process.uptime); - data.os.freemem = (data.os.freemem / 1000000).toFixed(2); - data.os.totalmem = (data.os.totalmem / 1000000).toFixed(2); + data.os.freemem = (data.os.freemem / (1024 * 1024 * 1024)).toFixed(2); + data.os.totalmem = (data.os.totalmem / (1024 * 1024 * 1024)).toFixed(2); + data.os.usedmem = (data.os.totalmem - data.os.freemem).toFixed(2); const [stats, gitInfo] = await Promise.all([ rooms.getLocalStats(), getGitInfo(), @@ -105,6 +105,16 @@ async function getNodeInfo() { return data; } +function getCpuUsage() { + const newUsage = process.cpuUsage(); + const diff = (newUsage.user + newUsage.system) - (previousUsage.user + previousUsage.system); + const now = Date.now(); + const result = diff / ((now - usageStartDate) * 1000) * 100; + previousUsage = newUsage; + usageStartDate = now; + return result.toFixed(2); +} + function humanReadableUptime(seconds) { if (seconds < 60) { return `${Math.floor(seconds)}s`; diff --git a/src/views/admin/development/info.tpl b/src/views/admin/development/info.tpl index 604e13bfb7..bb113ab0d9 100644 --- a/src/views/admin/development/info.tpl +++ b/src/views/admin/development/info.tpl @@ -17,7 +17,8 @@ [[admin/development/info:online]] [[admin/development/info:git]] [[admin/development/info:cpu-usage]] - [[admin/development/info:memory]] + [[admin/development/info:process-memory]] + [[admin/development/info:system-memory]] [[admin/development/info:load]] [[admin/development/info:uptime]] @@ -38,8 +39,14 @@ {info.stats.socketCount} {info.git.branch}@{info.git.hashShort} - {info.process.cpuUsage.user} / {info.process.cpuUsage.system} - {info.process.memoryUsage.humanReadable} mb / {info.os.freemem} mb + {info.process.cpuUsage}% + + {info.process.memoryUsage.humanReadable} gb + + + {info.os.usedmem} gb / + {info.os.totalmem} gb + {info.os.load} {info.process.uptimeHumanReadable} From 91676c6c7cf29f631da2cf084635d17bba464f58 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Sun, 7 Nov 2021 02:07:52 +0000 Subject: [PATCH 370/412] chore(i18n): fallback strings for new resources: nodebb.admin-development-info --- public/language/ar/admin/development/info.json | 6 +++++- public/language/bg/admin/development/info.json | 6 +++++- public/language/bn/admin/development/info.json | 6 +++++- public/language/cs/admin/development/info.json | 6 +++++- public/language/da/admin/development/info.json | 6 +++++- public/language/de/admin/development/info.json | 6 +++++- public/language/el/admin/development/info.json | 6 +++++- public/language/en-US/admin/development/info.json | 6 +++++- public/language/en-x-pirate/admin/development/info.json | 6 +++++- public/language/es/admin/development/info.json | 6 +++++- public/language/et/admin/development/info.json | 6 +++++- public/language/fa-IR/admin/development/info.json | 6 +++++- public/language/fi/admin/development/info.json | 6 +++++- public/language/fr/admin/development/info.json | 6 +++++- public/language/gl/admin/development/info.json | 6 +++++- public/language/he/admin/development/info.json | 6 +++++- public/language/hr/admin/development/info.json | 6 +++++- public/language/hu/admin/development/info.json | 6 +++++- public/language/id/admin/development/info.json | 6 +++++- public/language/it/admin/development/info.json | 6 +++++- public/language/ja/admin/development/info.json | 6 +++++- public/language/ko/admin/development/info.json | 6 +++++- public/language/lt/admin/development/info.json | 6 +++++- public/language/lv/admin/development/info.json | 6 +++++- public/language/ms/admin/development/info.json | 6 +++++- public/language/nb/admin/development/info.json | 6 +++++- public/language/nl/admin/development/info.json | 6 +++++- public/language/pl/admin/development/info.json | 6 +++++- public/language/pt-BR/admin/development/info.json | 6 +++++- public/language/pt-PT/admin/development/info.json | 6 +++++- public/language/ro/admin/development/info.json | 6 +++++- public/language/ru/admin/development/info.json | 6 +++++- public/language/rw/admin/development/info.json | 6 +++++- public/language/sc/admin/development/info.json | 6 +++++- public/language/sk/admin/development/info.json | 6 +++++- public/language/sl/admin/development/info.json | 6 +++++- public/language/sr/admin/development/info.json | 6 +++++- public/language/sv/admin/development/info.json | 6 +++++- public/language/th/admin/development/info.json | 6 +++++- public/language/tr/admin/development/info.json | 6 +++++- public/language/uk/admin/development/info.json | 6 +++++- public/language/vi/admin/development/info.json | 6 +++++- public/language/zh-CN/admin/development/info.json | 6 +++++- public/language/zh-TW/admin/development/info.json | 6 +++++- 44 files changed, 220 insertions(+), 44 deletions(-) diff --git a/public/language/ar/admin/development/info.json b/public/language/ar/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/ar/admin/development/info.json +++ b/public/language/ar/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/bg/admin/development/info.json b/public/language/bg/admin/development/info.json index 01e90f0a73..c03576fce6 100644 --- a/public/language/bg/admin/development/info.json +++ b/public/language/bg/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "на линия", "git": "git", - "memory": "памет", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "натоварване на системата", "cpu-usage": "използване на процесора", "uptime": "активно време", diff --git a/public/language/bn/admin/development/info.json b/public/language/bn/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/bn/admin/development/info.json +++ b/public/language/bn/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/cs/admin/development/info.json b/public/language/cs/admin/development/info.json index a70c980f85..c47e061cb2 100644 --- a/public/language/cs/admin/development/info.json +++ b/public/language/cs/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "připojen", "git": "git", - "memory": "paměť", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "zatížení systému", "cpu-usage": "využití CPU", "uptime": "čas spuštění", diff --git a/public/language/da/admin/development/info.json b/public/language/da/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/da/admin/development/info.json +++ b/public/language/da/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/de/admin/development/info.json b/public/language/de/admin/development/info.json index 8c04a3a0f0..c0b65f6781 100644 --- a/public/language/de/admin/development/info.json +++ b/public/language/de/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "Node.js Version", "online": "Online", "git": "git", - "memory": "Speicher", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "Systemlast", "cpu-usage": "CPU Benutzung", "uptime": "Uptime", diff --git a/public/language/el/admin/development/info.json b/public/language/el/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/el/admin/development/info.json +++ b/public/language/el/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/en-US/admin/development/info.json b/public/language/en-US/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/en-US/admin/development/info.json +++ b/public/language/en-US/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/en-x-pirate/admin/development/info.json b/public/language/en-x-pirate/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/en-x-pirate/admin/development/info.json +++ b/public/language/en-x-pirate/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/es/admin/development/info.json b/public/language/es/admin/development/info.json index 385c3a56a9..5f934d3a40 100644 --- a/public/language/es/admin/development/info.json +++ b/public/language/es/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "en-linea", "git": "git", - "memory": "memoria", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "carga del sistema", "cpu-usage": "uso del cpu", "uptime": "tiempo de actividad", diff --git a/public/language/et/admin/development/info.json b/public/language/et/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/et/admin/development/info.json +++ b/public/language/et/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/fa-IR/admin/development/info.json b/public/language/fa-IR/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/fa-IR/admin/development/info.json +++ b/public/language/fa-IR/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/fi/admin/development/info.json b/public/language/fi/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/fi/admin/development/info.json +++ b/public/language/fi/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/fr/admin/development/info.json b/public/language/fr/admin/development/info.json index 479b30a80f..5be9541a32 100644 --- a/public/language/fr/admin/development/info.json +++ b/public/language/fr/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "en ligne", "git": "git", - "memory": "mémoire", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "Charge du système", "cpu-usage": "Utilisation du processeur", "uptime": "disponibilité", diff --git a/public/language/gl/admin/development/info.json b/public/language/gl/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/gl/admin/development/info.json +++ b/public/language/gl/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/he/admin/development/info.json b/public/language/he/admin/development/info.json index 4c60fef05a..83bdfa2cc7 100644 --- a/public/language/he/admin/development/info.json +++ b/public/language/he/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "מקוון", "git": "git", - "memory": "זיכרון", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "טעינת מערכת", "cpu-usage": "שימוש ב-CPU", "uptime": "משך זמן פעולת המערכת ללא השבתה", diff --git a/public/language/hr/admin/development/info.json b/public/language/hr/admin/development/info.json index 888f9f053f..0eb118a954 100644 --- a/public/language/hr/admin/development/info.json +++ b/public/language/hr/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "Na mreži", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/hu/admin/development/info.json b/public/language/hu/admin/development/info.json index fb32d22f96..d67e35f340 100644 --- a/public/language/hu/admin/development/info.json +++ b/public/language/hu/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memória", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "üzemidő", diff --git a/public/language/id/admin/development/info.json b/public/language/id/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/id/admin/development/info.json +++ b/public/language/id/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/it/admin/development/info.json b/public/language/it/admin/development/info.json index 2d32a277a5..174bc38169 100644 --- a/public/language/it/admin/development/info.json +++ b/public/language/it/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memoria", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "carico sistema", "cpu-usage": "uso CPU", "uptime": "tempo di caricamento", diff --git a/public/language/ja/admin/development/info.json b/public/language/ja/admin/development/info.json index 8d70eb611c..f70dd00849 100644 --- a/public/language/ja/admin/development/info.json +++ b/public/language/ja/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "オンライン", "git": "git", - "memory": "メモリ", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "稼働時間", diff --git a/public/language/ko/admin/development/info.json b/public/language/ko/admin/development/info.json index 6b921c1d08..640110f2d0 100644 --- a/public/language/ko/admin/development/info.json +++ b/public/language/ko/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "온라인", "git": "git", - "memory": "메모리", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "시스템 로드", "cpu-usage": "cpu 사용량", "uptime": "업타임", diff --git a/public/language/lt/admin/development/info.json b/public/language/lt/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/lt/admin/development/info.json +++ b/public/language/lt/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/lv/admin/development/info.json b/public/language/lv/admin/development/info.json index a8230d80e3..d07a526789 100644 --- a/public/language/lv/admin/development/info.json +++ b/public/language/lv/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "tiešsaistē", "git": "git", - "memory": "atmiņa", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "darbspējas laiks", diff --git a/public/language/ms/admin/development/info.json b/public/language/ms/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/ms/admin/development/info.json +++ b/public/language/ms/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/nb/admin/development/info.json b/public/language/nb/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/nb/admin/development/info.json +++ b/public/language/nb/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/nl/admin/development/info.json b/public/language/nl/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/nl/admin/development/info.json +++ b/public/language/nl/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/pl/admin/development/info.json b/public/language/pl/admin/development/info.json index 117a8c0c56..3cfe72b22d 100644 --- a/public/language/pl/admin/development/info.json +++ b/public/language/pl/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "dostępny", "git": "git", - "memory": "pamięć", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "obciążenie systemu", "cpu-usage": "użycie procesora", "uptime": "czas działania", diff --git a/public/language/pt-BR/admin/development/info.json b/public/language/pt-BR/admin/development/info.json index cb67c31ed3..e1a5b6b618 100644 --- a/public/language/pt-BR/admin/development/info.json +++ b/public/language/pt-BR/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memória", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "carga do sistema", "cpu-usage": "uso da cpu", "uptime": "tempo de atividade", diff --git a/public/language/pt-PT/admin/development/info.json b/public/language/pt-PT/admin/development/info.json index 1bbac03c82..e88ef6e50d 100644 --- a/public/language/pt-PT/admin/development/info.json +++ b/public/language/pt-PT/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memória", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "carga do sistema", "cpu-usage": "uso cpu", "uptime": "tempo de atividade", diff --git a/public/language/ro/admin/development/info.json b/public/language/ro/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/ro/admin/development/info.json +++ b/public/language/ro/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/ru/admin/development/info.json b/public/language/ru/admin/development/info.json index 0087dac3a0..63d6faae67 100644 --- a/public/language/ru/admin/development/info.json +++ b/public/language/ru/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "онлайн", "git": "git", - "memory": "память", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "системная загрузка", "cpu-usage": "загрузка процессора", "uptime": "продолжительность работы", diff --git a/public/language/rw/admin/development/info.json b/public/language/rw/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/rw/admin/development/info.json +++ b/public/language/rw/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/sc/admin/development/info.json b/public/language/sc/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/sc/admin/development/info.json +++ b/public/language/sc/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/sk/admin/development/info.json b/public/language/sk/admin/development/info.json index 1fec788589..62f5cb9863 100644 --- a/public/language/sk/admin/development/info.json +++ b/public/language/sk/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "pripojený", "git": "git", - "memory": "pamäť", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "čas spustenia", diff --git a/public/language/sl/admin/development/info.json b/public/language/sl/admin/development/info.json index 7187011bb0..4c469cc598 100644 --- a/public/language/sl/admin/development/info.json +++ b/public/language/sl/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "na spletu", "git": "git", - "memory": "spomin", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "obremenitev sistema", "cpu-usage": "uporaba procesorja", "uptime": "čas delovanja", diff --git a/public/language/sr/admin/development/info.json b/public/language/sr/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/sr/admin/development/info.json +++ b/public/language/sr/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/sv/admin/development/info.json b/public/language/sv/admin/development/info.json index 1003af1a5f..11202d9c3a 100644 --- a/public/language/sv/admin/development/info.json +++ b/public/language/sv/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "memory", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/th/admin/development/info.json b/public/language/th/admin/development/info.json index f19273f0f9..504759aa23 100644 --- a/public/language/th/admin/development/info.json +++ b/public/language/th/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "หน่วยความจำ", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "ระยะเวลาการทำงาน", diff --git a/public/language/tr/admin/development/info.json b/public/language/tr/admin/development/info.json index 2feb725487..4f80b51f8d 100644 --- a/public/language/tr/admin/development/info.json +++ b/public/language/tr/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "çevrimiçi", "git": "git", - "memory": "hafıza", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "sistem yüklemesi", "cpu-usage": "cpu kullanımı", "uptime": "kesintisiz çalışma süresi", diff --git a/public/language/uk/admin/development/info.json b/public/language/uk/admin/development/info.json index ed7b89737e..c28dc7bb38 100644 --- a/public/language/uk/admin/development/info.json +++ b/public/language/uk/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "memory": "пам'ять", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "system load", "cpu-usage": "cpu usage", "uptime": "uptime", diff --git a/public/language/vi/admin/development/info.json b/public/language/vi/admin/development/info.json index 3b14058737..8d9d08806b 100644 --- a/public/language/vi/admin/development/info.json +++ b/public/language/vi/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "trực tuyến", "git": "git", - "memory": "bộ nhớ", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "tải hệ thống", "cpu-usage": "sử dụng cpu", "uptime": "thời gian hoạt động", diff --git a/public/language/zh-CN/admin/development/info.json b/public/language/zh-CN/admin/development/info.json index 4cf78389ba..8d4e8b4678 100644 --- a/public/language/zh-CN/admin/development/info.json +++ b/public/language/zh-CN/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "在线", "git": "git", - "memory": "内存", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "系统负载", "cpu-usage": "CPU 使用情况", "uptime": "运行时间", diff --git a/public/language/zh-TW/admin/development/info.json b/public/language/zh-TW/admin/development/info.json index fc6c50e514..9b2d42dcfd 100644 --- a/public/language/zh-TW/admin/development/info.json +++ b/public/language/zh-TW/admin/development/info.json @@ -8,7 +8,11 @@ "nodejs": "nodejs", "online": "在線", "git": "git", - "memory": "記憶體", + "process-memory": "process memory", + "system-memory": "system memory", + "used-memory-process": "Used memory by process", + "used-memory-os": "Used system memory", + "total-memory-os": "Total system memory", "load": "系統負載", "cpu-usage": "CPU 使用情況", "uptime": "運行時間", From c1f5889f1384e92085bd505206b59c26049e4b19 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Sun, 7 Nov 2021 18:47:05 +0000 Subject: [PATCH 371/412] fix(deps): update dependency html-to-text to v8.1.0 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index a9be5da3fc..4c0ee01e8d 100644 --- a/install/package.json +++ b/install/package.json @@ -61,7 +61,7 @@ "express-useragent": "^1.0.15", "graceful-fs": "^4.2.6", "helmet": "^4.4.1", - "html-to-text": "8.0.0", + "html-to-text": "8.1.0", "ipaddr.js": "^2.0.0", "jquery": "3.6.0", "jquery-deserialize": "2.0.0", From b736347cd329e42f85492cb6fdc90c85ea801038 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Mon, 8 Nov 2021 09:07:54 +0000 Subject: [PATCH 372/412] Latest translations and fallbacks --- public/language/bg/admin/development/info.json | 10 +++++----- public/language/fr/admin/development/info.json | 10 +++++----- public/language/it/admin/development/info.json | 10 +++++----- public/language/it/admin/settings/navigation.json | 4 ++-- public/language/vi/admin/development/info.json | 10 +++++----- 5 files changed, 22 insertions(+), 22 deletions(-) diff --git a/public/language/bg/admin/development/info.json b/public/language/bg/admin/development/info.json index c03576fce6..08f70c0692 100644 --- a/public/language/bg/admin/development/info.json +++ b/public/language/bg/admin/development/info.json @@ -8,11 +8,11 @@ "nodejs": "nodejs", "online": "на линия", "git": "git", - "process-memory": "process memory", - "system-memory": "system memory", - "used-memory-process": "Used memory by process", - "used-memory-os": "Used system memory", - "total-memory-os": "Total system memory", + "process-memory": "памет на процеса", + "system-memory": "системна памет", + "used-memory-process": "Използвана памет от процеса", + "used-memory-os": "Използвана системна памет", + "total-memory-os": "Обща системна памет", "load": "натоварване на системата", "cpu-usage": "използване на процесора", "uptime": "активно време", diff --git a/public/language/fr/admin/development/info.json b/public/language/fr/admin/development/info.json index 5be9541a32..2b20a90ad6 100644 --- a/public/language/fr/admin/development/info.json +++ b/public/language/fr/admin/development/info.json @@ -8,11 +8,11 @@ "nodejs": "nodejs", "online": "en ligne", "git": "git", - "process-memory": "process memory", - "system-memory": "system memory", - "used-memory-process": "Used memory by process", - "used-memory-os": "Used system memory", - "total-memory-os": "Total system memory", + "process-memory": "mémoire de processus", + "system-memory": "mémoire système", + "used-memory-process": "Mémoire utilisée par processus", + "used-memory-os": "Mémoire système utilisée", + "total-memory-os": "Mémoire système totale", "load": "Charge du système", "cpu-usage": "Utilisation du processeur", "uptime": "disponibilité", diff --git a/public/language/it/admin/development/info.json b/public/language/it/admin/development/info.json index 174bc38169..28b9bf2831 100644 --- a/public/language/it/admin/development/info.json +++ b/public/language/it/admin/development/info.json @@ -8,11 +8,11 @@ "nodejs": "nodejs", "online": "online", "git": "git", - "process-memory": "process memory", - "system-memory": "system memory", - "used-memory-process": "Used memory by process", - "used-memory-os": "Used system memory", - "total-memory-os": "Total system memory", + "process-memory": "memoria di processo", + "system-memory": "memoria di sistema", + "used-memory-process": "Memoria usata dal processo", + "used-memory-os": "Memoria di sistema usata", + "total-memory-os": "Memoria totale del sistema", "load": "carico sistema", "cpu-usage": "uso CPU", "uptime": "tempo di caricamento", diff --git a/public/language/it/admin/settings/navigation.json b/public/language/it/admin/settings/navigation.json index 77ba9c2f42..75607ccce6 100644 --- a/public/language/it/admin/settings/navigation.json +++ b/public/language/it/admin/settings/navigation.json @@ -11,8 +11,8 @@ "properties": "Proprietà:", "groups": "Gruppi:", "open-new-window": "Apri in una nuova finestra", - "dropdown": "Dropdown", - "dropdown-placeholder": "Place your dropdown menu items below, ie:
    <li><a href="https://myforum.com">Link 1</a></li>", + "dropdown": "Menu a tendina", + "dropdown-placeholder": "Posiziona le voci del tuo menu a tendina in basso, ad esempio:
    <li><a href="https://myforum.com">Link 1</a></li>", "btn.delete": "Elimina", "btn.disable": "Disabilita", diff --git a/public/language/vi/admin/development/info.json b/public/language/vi/admin/development/info.json index 8d9d08806b..4a76411c21 100644 --- a/public/language/vi/admin/development/info.json +++ b/public/language/vi/admin/development/info.json @@ -8,11 +8,11 @@ "nodejs": "nodejs", "online": "trực tuyến", "git": "git", - "process-memory": "process memory", - "system-memory": "system memory", - "used-memory-process": "Used memory by process", - "used-memory-os": "Used system memory", - "total-memory-os": "Total system memory", + "process-memory": "xử lý bộ nhớ", + "system-memory": "bộ nhớ hệ thống", + "used-memory-process": "Đã sử dụng bộ nhớ theo quy trình", + "used-memory-os": "Bộ nhớ hệ thống đã sử dụng", + "total-memory-os": "Tổng bộ nhớ hệ thống", "load": "tải hệ thống", "cpu-usage": "sử dụng cpu", "uptime": "thời gian hoạt động", From 98ebc4d9aced4f8011d004547554e5746b3d6efa Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Mon, 8 Nov 2021 10:02:38 +0000 Subject: [PATCH 373/412] fix(deps): update dependency socket.io to v4.3.2 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 4c0ee01e8d..e59766f156 100644 --- a/install/package.json +++ b/install/package.json @@ -119,7 +119,7 @@ "sharp": "0.29.2", "sitemap": "^7.0.0", "slideout": "1.0.1", - "socket.io": "4.3.1", + "socket.io": "4.3.2", "socket.io-adapter-cluster": "^1.0.1", "socket.io-client": "4.3.2", "@socket.io/redis-adapter": "7.0.0", From 1a22b0ecf2c7b08bc08551dc67a8bad702a585cb Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Mon, 8 Nov 2021 15:31:38 +0000 Subject: [PATCH 374/412] fix(deps): update dependency nodebb-plugin-mentions to v3.0.2 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index e59766f156..db67e3b86b 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "3.0.1", + "nodebb-plugin-mentions": "3.0.2", "nodebb-plugin-spam-be-gone": "0.7.11", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.3.1", From b912a564e379fd7eb73ff8e3a1c2c103df962464 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Mon, 8 Nov 2021 15:16:39 -0500 Subject: [PATCH 375/412] fix: accidentally not clearing email when said email is confirmed for a different uid --- src/user/email.js | 6 ++++++ test/user.js | 16 ++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/src/user/email.js b/src/user/email.js index 85162b8414..d6d2d32b4d 100644 --- a/src/user/email.js +++ b/src/user/email.js @@ -143,6 +143,12 @@ UserEmail.confirmByCode = async function (code, sessionId) { throw new Error('[[error:invalid-data]]'); } + // If another uid has the same email, remove it + const oldUid = await db.sortedSetScore('email:uid', confirmObj.email.toLowerCase()); + if (oldUid) { + await UserEmail.remove(oldUid, sessionId); + } + const oldEmail = await user.getUserField(confirmObj.uid, 'email'); if (oldEmail && confirmObj.email !== oldEmail) { await UserEmail.remove(confirmObj.uid, sessionId); diff --git a/test/user.js b/test/user.js index e74eb8252d..671cc06d20 100644 --- a/test/user.js +++ b/test/user.js @@ -2462,6 +2462,22 @@ describe('User', () => { assert.strictEqual(parseInt(confirmed, 10), 1); assert.strictEqual(isVerified, true); }); + + it('should remove the email from a different account if the email is already in use', async () => { + const email = 'confirm2@me.com'; + const uid = await User.create({ + username: 'confirme3', + }); + + const oldUid = await db.sortedSetScore('email:uid', email); + const code = await User.email.sendValidationEmail(uid, email); + await User.email.confirmByCode(code); + + const oldUserData = await User.getUserData(oldUid); + + assert.strictEqual((await db.sortedSetScore('email:uid', email)), uid); + assert.strictEqual(oldUserData.email, ''); + }); }); describe('user jobs', () => { From c1ac29128494df9b8ad9e1d25166ce340eed8014 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Mon, 8 Nov 2021 15:36:37 -0500 Subject: [PATCH 376/412] fix: ability to enumerate email via updateProfile method --- src/user/profile.js | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/src/user/profile.js b/src/user/profile.js index 2748690b81..a8d1b02d1d 100644 --- a/src/user/profile.js +++ b/src/user/profile.js @@ -71,7 +71,7 @@ module.exports = function (User) { }; async function validateData(callerUid, data) { - await isEmailAvailable(data, data.uid); + await isEmailValid(data); await isUsernameAvailable(data, data.uid); await isWebsiteValid(callerUid, data); await isAboutMeValid(callerUid, data); @@ -82,7 +82,7 @@ module.exports = function (User) { isGroupTitleValid(data); } - async function isEmailAvailable(data, uid) { + async function isEmailValid(data) { if (!data.email) { return; } @@ -91,14 +91,6 @@ module.exports = function (User) { if (!utils.isEmailValid(data.email)) { throw new Error('[[error:invalid-email]]'); } - const email = await User.getUserField(uid, 'email'); - if (email === data.email) { - return; - } - const available = await User.email.available(data.email); - if (!available) { - throw new Error('[[error:email-taken]]'); - } } async function isUsernameAvailable(data, uid) { From 0a7ff2085e63a5c26b491e2802a52f105ed761dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 16:55:25 -0500 Subject: [PATCH 377/412] refactor: remove jshint --- .jsbeautifyrc | 17 ---------- .jshintrc | 91 --------------------------------------------------- 2 files changed, 108 deletions(-) delete mode 100644 .jsbeautifyrc delete mode 100644 .jshintrc diff --git a/.jsbeautifyrc b/.jsbeautifyrc deleted file mode 100644 index d76e93f2d5..0000000000 --- a/.jsbeautifyrc +++ /dev/null @@ -1,17 +0,0 @@ -{ - "indent_size": 4, - "indent_char": " ", - "indent_level": 0, - "indent_with_tabs": true, - "preserve_newlines": true, - "max_preserve_newlines": 10, - "jslint_happy": true, - "brace_style": "collapse", - "keep_array_indentation": false, - "keep_function_indentation": false, - "space_before_conditional": true, - "break_chained_methods": false, - "eval_code": false, - "unescape_strings": false, - "wrap_line_length": 0 -} \ No newline at end of file diff --git a/.jshintrc b/.jshintrc deleted file mode 100644 index 37c22ddcf9..0000000000 --- a/.jshintrc +++ /dev/null @@ -1,91 +0,0 @@ -{ - // JSHint Default Configuration File (as on JSHint website) - // See http://jshint.com/docs/ for more details - - "maxerr" : 50, // {int} Maximum error before stopping - - "esversion": 9, - - // Enforcing - "bitwise" : true, // true: Prohibit bitwise operators (&, |, ^, etc.) - "camelcase" : false, // true: Identifiers must be in camelCase - "curly" : true, // true: Require {} for every new block or scope - "eqeqeq" : true, // true: Require triple equals (===) for comparison - "forin" : true, // true: Require filtering for..in loops with obj.hasOwnProperty() - "immed" : false, // true: Require immediate invocations to be wrapped in parens e.g. `(function () { } ());` - "indent" : 4, // {int} Number of spaces to use for indentation - "latedef" : false, // true: Require variables/functions to be defined before being used - "newcap" : false, // true: Require capitalization of all constructor functions e.g. `new F()` - "noarg" : true, // true: Prohibit use of `arguments.caller` and `arguments.callee` - "noempty" : true, // true: Prohibit use of empty blocks - "nonew" : false, // true: Prohibit use of constructors for side-effects (without assignment) - "plusplus" : false, // true: Prohibit use of `++` & `--` - "quotmark" : false, // Quotation mark consistency: - // false : do nothing (default) - // true : ensure whatever is used is consistent - // "single" : require single quotes - // "double" : require double quotes - "undef" : true, // true: Require all non-global variables to be declared (prevents global leaks) - "unused" : true, // true: Require all defined variables be used - "strict" : true, // true: Requires all functions run in ES5 Strict Mode - "trailing" : false, // true: Prohibit trailing whitespaces - "maxparams" : false, // {int} Max number of formal params allowed per function - "maxdepth" : false, // {int} Max depth of nested blocks (within functions) - "maxstatements" : false, // {int} Max number statements per function - "maxcomplexity" : false, // {int} Max cyclomatic complexity per function - "maxlen" : false, // {int} Max number of characters per line - - // Relaxing - "asi" : false, // true: Tolerate Automatic Semicolon Insertion (no semicolons) - "boss" : false, // true: Tolerate assignments where comparisons would be expected - "debug" : false, // true: Allow debugger statements e.g. browser breakpoints. - "eqnull" : false, // true: Tolerate use of `== null` - "es5" : false, // true: Allow ES5 syntax (ex: getters and setters) - "esnext" : false, // true: Allow ES.next (ES6) syntax (ex: `const`) - "moz" : false, // true: Allow Mozilla specific syntax (extends and overrides esnext features) - // (ex: `for each`, multiple try/catch, function expression…) - "evil" : false, // true: Tolerate use of `eval` and `new Function()` - "expr" : false, // true: Tolerate `ExpressionStatement` as Programs - "funcscope" : false, // true: Tolerate defining variables inside control statements" - "globalstrict" : false, // true: Allow global "use strict" (also enables 'strict') - "iterator" : false, // true: Tolerate using the `__iterator__` property - "lastsemic" : false, // true: Tolerate omitting a semicolon for the last statement of a 1-line block - "laxbreak" : false, // true: Tolerate possibly unsafe line breakings - "laxcomma" : false, // true: Tolerate comma-first style coding - "loopfunc" : false, // true: Tolerate functions being defined in loops - "multistr" : false, // true: Tolerate multi-line strings - "proto" : false, // true: Tolerate using the `__proto__` property - "scripturl" : false, // true: Tolerate script-targeted URLs - "smarttabs" : false, // true: Tolerate mixed tabs/spaces when used for alignment - "shadow" : false, // true: Allows re-define variables later in code e.g. `var x=1; x=2;` - "sub" : false, // true: Tolerate using `[]` notation when it can still be expressed in dot notation - "supernew" : false, // true: Tolerate `new function () { ... };` and `new Object;` - "validthis" : false, // true: Tolerate using this in a non-constructor function - - // Environments - "browser" : true, // Web Browser (window, document, etc) - "couch" : false, // CouchDB - "devel" : true, // Development/debugging (alert, confirm, etc) - "dojo" : false, // Dojo Toolkit - "jquery" : true, // jQuery - "mootools" : false, // MooTools - "node" : true, // Node.js - "nonstandard" : false, // Widely adopted globals (escape, unescape, etc) - "prototypejs" : false, // Prototype and Scriptaculous - "rhino" : false, // Rhino - "worker" : false, // Web Workers - "wsh" : false, // Windows Scripting Host - "yui" : false, // Yahoo User Interface - "mocha": true, - - // Legacy - "nomen" : false, // true: Prohibit dangling `_` in variables - "onevar" : false, // true: Allow only one `var` statement per function - "passfail" : false, // true: Stop on first error - "white" : false, // true: Check against strict whitespace and indentation rules - - // Custom Globals - "globals" : { - "Promise": true - } // additional predefined global variables -} \ No newline at end of file From 518552543d2f0b322235ca83c3f1c96a947f11b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 20:40:41 -0500 Subject: [PATCH 378/412] refactor: move warnings/messages out of app.js --- public/src/app.js | 132 +--------------------------- public/src/client/chats/messages.js | 6 +- public/src/modules/messages.js | 100 +++++++++++++++++++++ src/meta/js.js | 1 + 4 files changed, 109 insertions(+), 130 deletions(-) create mode 100644 public/src/modules/messages.js diff --git a/public/src/app.js b/public/src/app.js index e6f3e95e1c..86cc0bc11d 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -11,9 +11,6 @@ app.cacheBuster = null; (function () { let appLoaded = false; - const params = utils.params(); - let showWelcomeMessage = !!params.loggedin; - let registerMessage = params.register; const isTouchDevice = utils.isTouchDevice(); app.cacheBuster = config['cache-buster']; @@ -97,8 +94,7 @@ app.cacheBuster = null; }); createHeaderTooltips(); - app.showEmailConfirmWarning(); - app.showCookieWarning(); + registerServiceWorker(); require([ @@ -106,11 +102,12 @@ app.cacheBuster = null; 'helpers', 'forum/pagination', 'translator', + 'messages', 'forum/unread', 'forum/header/notifications', 'forum/header/chat', 'timeago/jquery.timeago', - ], function (taskbar, helpers, pagination, translator, unread, notifications, chat) { + ], function (taskbar, helpers, pagination, translator, messages, unread, notifications, chat) { notifications.prepareDOM(); chat.prepareDOM(); translator.prepareDOM(); @@ -123,7 +120,7 @@ app.cacheBuster = null; } function finishLoad() { hooks.fire('action:app.load'); - app.showMessages(); + messages.show(); appLoaded = true; } overrides.overrideTimeago(); @@ -332,54 +329,6 @@ app.cacheBuster = null; app.createStatusTooltips(); }; - app.showMessages = function () { - const messages = { - login: { - format: 'alert', - title: '[[global:welcome_back]] ' + app.user.username + '!', - message: '[[global:you_have_successfully_logged_in]]', - }, - register: { - format: 'modal', - }, - }; - - function showAlert(type, message) { - switch (messages[type].format) { - case 'alert': - app.alert({ - type: 'success', - title: messages[type].title, - message: messages[type].message, - timeout: 5000, - }); - break; - - case 'modal': - require(['bootbox'], function (bootbox) { - bootbox.alert({ - title: messages[type].title, - message: message || messages[type].message, - }); - }); - break; - } - } - - if (showWelcomeMessage) { - showWelcomeMessage = false; - $(document).ready(function () { - showAlert('login'); - }); - } - if (registerMessage) { - $(document).ready(function () { - showAlert('register', utils.escapeHTML(decodeURIComponent(registerMessage))); - registerMessage = false; - }); - } - }; - app.openChat = function (roomId, uid) { if (!app.user.uid) { return app.alertError('[[error:not-logged-in]]'); @@ -758,46 +707,6 @@ app.cacheBuster = null; }); }; - app.showEmailConfirmWarning = async (err) => { - const storage = await app.require('storage'); - - if (!config.emailPrompt || !app.user.uid || parseInt(storage.getItem('email-confirm-dismiss'), 10) === 1) { - return; - } - const msg = { - alert_id: 'email_confirm', - type: 'warning', - timeout: 0, - closefn: () => { - storage.setItem('email-confirm-dismiss', 1); - }, - }; - - if (!app.user.email) { - msg.message = '[[error:no-email-to-confirm]]'; - msg.clickfn = function () { - app.removeAlert('email_confirm'); - ajaxify.go('user/' + app.user.userslug + '/edit/email'); - }; - app.alert(msg); - } else if (!app.user['email:confirmed'] && !app.user.isEmailConfirmSent) { - msg.message = err ? err.message : '[[error:email-not-confirmed]]'; - msg.clickfn = function () { - app.removeAlert('email_confirm'); - socket.emit('user.emailConfirm', {}, function (err) { - if (err) { - return app.alertError(err.message); - } - app.alertSuccess('[[notifications:email-confirm-sent]]'); - }); - }; - app.alert(msg); - } else if (!app.user['email:confirmed'] && app.user.isEmailConfirmSent) { - msg.message = '[[error:email-not-confirmed-email-sent]]'; - app.alert(msg); - } - }; - app.parseAndTranslate = function (template, blockName, data, callback) { if (typeof blockName !== 'string') { callback = data; @@ -822,39 +731,6 @@ app.cacheBuster = null; }); }; - app.showCookieWarning = function () { - require(['translator', 'storage'], function (translator, storage) { - if (!config.cookies.enabled || !navigator.cookieEnabled) { - // Skip warning if cookie consent subsystem disabled (obviously), or cookies not in use - return; - } else if (window.location.pathname.startsWith(config.relative_path + '/admin')) { - // No need to show cookie consent warning in ACP - return; - } else if (storage.getItem('cookieconsent') === '1') { - return; - } - - config.cookies.message = translator.unescape(config.cookies.message); - config.cookies.dismiss = translator.unescape(config.cookies.dismiss); - config.cookies.link = translator.unescape(config.cookies.link); - config.cookies.link_url = translator.unescape(config.cookies.link_url); - - app.parseAndTranslate('partials/cookie-consent', config.cookies, function (html) { - $(document.body).append(html); - $(document.body).addClass('cookie-consent-open'); - - const warningEl = $('.cookie-consent'); - const dismissEl = warningEl.find('button'); - dismissEl.on('click', function () { - // Save consent cookie and remove warning element - storage.setItem('cookieconsent', '1'); - warningEl.remove(); - $(document.body).removeClass('cookie-consent-open'); - }); - }); - }); - }; - function registerServiceWorker() { // Do not register for Safari browsers if (!ajaxify.data._locals.useragent.isSafari && 'serviceWorker' in navigator) { diff --git a/public/src/client/chats/messages.js b/public/src/client/chats/messages.js index 5d43497014..540edcae67 100644 --- a/public/src/client/chats/messages.js +++ b/public/src/client/chats/messages.js @@ -1,7 +1,9 @@ 'use strict'; -define('forum/chats/messages', ['components', 'translator', 'benchpress', 'hooks', 'bootbox'], function (components, translator, Benchpress, hooks, bootbox) { +define('forum/chats/messages', [ + 'components', 'translator', 'benchpress', 'hooks', 'bootbox', 'messages' +], function (components, translator, Benchpress, hooks, bootbox, messagesModule) { const messages = {}; messages.sendMessage = function (roomId, inputEl) { @@ -30,7 +32,7 @@ define('forum/chats/messages', ['components', 'translator', 'benchpress', 'hooks inputEl.val(msg); messages.updateRemainingLength(inputEl.parent()); if (err.message === '[[error:email-not-confirmed-chat]]') { - return app.showEmailConfirmWarning(err); + return messagesModule.showEmailConfirmWarning(err.message); } return app.alert({ diff --git a/public/src/modules/messages.js b/public/src/modules/messages.js new file mode 100644 index 0000000000..ad8992a893 --- /dev/null +++ b/public/src/modules/messages.js @@ -0,0 +1,100 @@ +'use strict'; + +define('messages', ['bootbox', 'translator', 'storage'], function (bootbox, translator, storage) { + const messages = {}; + + let showWelcomeMessage; + let registerMessage; + + messages.show = function () { + showQueryStringMessages(); + showCookieWarning(); + messages.showEmailConfirmWarning(); + }; + + messages.showEmailConfirmWarning = function (message) { + if (!config.emailPrompt || !app.user.uid || parseInt(storage.getItem('email-confirm-dismiss'), 10) === 1) { + return; + } + const msg = { + alert_id: 'email_confirm', + type: 'warning', + timeout: 0, + closefn: () => { + storage.setItem('email-confirm-dismiss', 1); + }, + }; + + if (!app.user.email) { + msg.message = '[[error:no-email-to-confirm]]'; + msg.clickfn = function () { + app.removeAlert('email_confirm'); + ajaxify.go('user/' + app.user.userslug + '/edit/email'); + }; + app.alert(msg); + } else if (!app.user['email:confirmed'] && !app.user.isEmailConfirmSent) { + msg.message = message || '[[error:email-not-confirmed]]'; + msg.clickfn = function () { + app.removeAlert('email_confirm'); + socket.emit('user.emailConfirm', {}, function (err) { + if (err) { + return app.alertError(err.message); + } + app.alertSuccess('[[notifications:email-confirm-sent]]'); + }); + }; + app.alert(msg); + } else if (!app.user['email:confirmed'] && app.user.isEmailConfirmSent) { + msg.message = '[[error:email-not-confirmed-email-sent]]'; + app.alert(msg); + } + }; + + function showCookieWarning() { + if (!config.cookies.enabled || !navigator.cookieEnabled || app.inAdmin || storage.getItem('cookieconsent') === '1') { + return; + } + + config.cookies.message = translator.unescape(config.cookies.message); + config.cookies.dismiss = translator.unescape(config.cookies.dismiss); + config.cookies.link = translator.unescape(config.cookies.link); + config.cookies.link_url = translator.unescape(config.cookies.link_url); + + app.parseAndTranslate('partials/cookie-consent', config.cookies, function (html) { + $(document.body).append(html); + $(document.body).addClass('cookie-consent-open'); + + const warningEl = $('.cookie-consent'); + const dismissEl = warningEl.find('button'); + dismissEl.on('click', function () { + // Save consent cookie and remove warning element + storage.setItem('cookieconsent', '1'); + warningEl.remove(); + $(document.body).removeClass('cookie-consent-open'); + }); + }); + } + + function showQueryStringMessages() { + const params = utils.params(); + showWelcomeMessage = !!params.loggedin; + registerMessage = params.register; + + if (showWelcomeMessage) { + app.alert({ + type: 'success', + title: '[[global:welcome_back]] ' + app.user.username + '!', + message: '[[global:you_have_successfully_logged_in]]', + timeout: 5000, + }); + } + + if (registerMessage) { + bootbox.alert({ + message: utils.escapeHTML(decodeURIComponent(registerMessage)), + }); + } + } + + return messages; +}); diff --git a/src/meta/js.js b/src/meta/js.js index 8e712ccf15..7d5fc7fb42 100644 --- a/src/meta/js.js +++ b/src/meta/js.js @@ -74,6 +74,7 @@ JS.scripts = { 'public/src/modules/helpers.js', 'public/src/modules/storage.js', 'public/src/modules/handleBack.js', + 'public/src/modules/messages.js', ], admin: [ From 3d2398ac4c6011c777229bf211919bf77bba29f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 20:48:32 -0500 Subject: [PATCH 379/412] test: lint --- public/src/client/chats/messages.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/client/chats/messages.js b/public/src/client/chats/messages.js index 540edcae67..7c11c1a479 100644 --- a/public/src/client/chats/messages.js +++ b/public/src/client/chats/messages.js @@ -2,7 +2,7 @@ define('forum/chats/messages', [ - 'components', 'translator', 'benchpress', 'hooks', 'bootbox', 'messages' + 'components', 'translator', 'benchpress', 'hooks', 'bootbox', 'messages', ], function (components, translator, Benchpress, hooks, bootbox, messagesModule) { const messages = {}; From 666fe209f05e1a2fa9a4b4f553268a9a93527cf2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 21:00:37 -0500 Subject: [PATCH 380/412] refactor: move session messages --- public/src/app.js | 33 --------------------------------- public/src/modules/messages.js | 26 ++++++++++++++++++++++++-- public/src/sockets.js | 23 +++++++++++++++++++++-- 3 files changed, 45 insertions(+), 37 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index 86cc0bc11d..d6f34dc2d3 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -212,39 +212,6 @@ app.cacheBuster = null; }); }; - app.handleInvalidSession = function () { - socket.disconnect(); - app.logout(false); - require(['bootbox'], function (bootbox) { - bootbox.alert({ - title: '[[error:invalid-session]]', - message: '[[error:invalid-session-text]]', - closeButton: false, - callback: function () { - window.location.reload(); - }, - }); - }); - }; - - app.handleSessionMismatch = () => { - if (app.flags._login || app.flags._logout) { - return; - } - - socket.disconnect(); - require(['bootbox'], function (bootbox) { - bootbox.alert({ - title: '[[error:session-mismatch]]', - message: '[[error:session-mismatch-text]]', - closeButton: false, - callback: function () { - window.location.reload(); - }, - }); - }); - }; - app.enterRoom = function (room, callback) { callback = callback || function () { }; if (socket && app.user.uid && app.currentRoom !== room) { diff --git a/public/src/modules/messages.js b/public/src/modules/messages.js index ad8992a893..0c1cfe2e71 100644 --- a/public/src/modules/messages.js +++ b/public/src/modules/messages.js @@ -1,6 +1,6 @@ 'use strict'; -define('messages', ['bootbox', 'translator', 'storage'], function (bootbox, translator, storage) { +define('messages', ['bootbox', 'translator', 'storage', 'alerts'], function (bootbox, translator, storage, alerts) { const messages = {}; let showWelcomeMessage; @@ -81,7 +81,7 @@ define('messages', ['bootbox', 'translator', 'storage'], function (bootbox, tran registerMessage = params.register; if (showWelcomeMessage) { - app.alert({ + alerts.alert({ type: 'success', title: '[[global:welcome_back]] ' + app.user.username + '!', message: '[[global:you_have_successfully_logged_in]]', @@ -96,5 +96,27 @@ define('messages', ['bootbox', 'translator', 'storage'], function (bootbox, tran } } + messages.showInvalidSession = function () { + bootbox.alert({ + title: '[[error:invalid-session]]', + message: '[[error:invalid-session-text]]', + closeButton: false, + callback: function () { + window.location.reload(); + }, + }); + }; + + messages.showSessionMismatch = function () { + bootbox.alert({ + title: '[[error:session-mismatch]]', + message: '[[error:session-mismatch-text]]', + closeButton: false, + callback: function () { + window.location.reload(); + }, + }); + }; + return messages; }); diff --git a/public/src/sockets.js b/public/src/sockets.js index 7615fe5b2b..c4763b28d5 100644 --- a/public/src/sockets.js +++ b/public/src/sockets.js @@ -80,11 +80,11 @@ socket = window.socket; socket.on('checkSession', function (uid) { if (parseInt(uid, 10) !== parseInt(app.user.uid, 10)) { - app.handleSessionMismatch(); + handleSessionMismatch(); } }); socket.on('event:invalid_session', () => { - app.handleInvalidSession(); + handleInvalidSession(); }); socket.on('setHostname', function (hostname) { @@ -126,6 +126,25 @@ socket = window.socket; }); } + function handleInvalidSession() { + socket.disconnect(); + app.logout(false); + require(['messages'], function (messages) { + messages.showInvalidSession(); + }); + } + + function handleSessionMismatch() { + if (app.flags._login || app.flags._logout) { + return; + } + + socket.disconnect(); + require(['messages'], function (messages) { + messages.showSessionMismatch(); + }); + } + function onConnect() { if (!reconnecting) { hooks.fire('action:connected'); From 1a9b15989b655fcf0d18e8c396957fe509eab701 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 21:31:49 -0500 Subject: [PATCH 381/412] refactor: move search functions from app.js to search module deprecate: app.handleSearch, use search.init(options) instead app.enableTopicSearch, use search.enableQuickSearch(options) instead app.prepareSearch, use search.showAndFocusInput() instead --- public/src/app.js | 222 ++----------------------------- public/src/client/topic.js | 4 +- public/src/client/topic/merge.js | 4 +- public/src/modules/search.js | 212 ++++++++++++++++++++++++++++- src/meta/js.js | 1 + 5 files changed, 228 insertions(+), 215 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index d6f34dc2d3..3374f1b68c 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -75,10 +75,6 @@ app.cacheBuster = null; app.load = function () { handleStatusChange(); - if (config.searchEnabled) { - app.handleSearch(); - } - $('body').on('click', '#new_topic', function (e) { e.preventDefault(); app.newTopic(); @@ -103,17 +99,19 @@ app.cacheBuster = null; 'forum/pagination', 'translator', 'messages', + 'search', 'forum/unread', 'forum/header/notifications', 'forum/header/chat', 'timeago/jquery.timeago', - ], function (taskbar, helpers, pagination, translator, messages, unread, notifications, chat) { + ], function (taskbar, helpers, pagination, translator, messages, search, unread, notifications, chat) { notifications.prepareDOM(); chat.prepareDOM(); translator.prepareDOM(); taskbar.init(); helpers.register(); pagination.init(); + search.init(); if (app.user.uid > 0) { unread.initUnreadTopics(); @@ -404,218 +402,24 @@ app.cacheBuster = null; } app.enableTopicSearch = function (options) { - if (!config.searchEnabled || !app.user.privileges['search:content']) { - return; - } - /* eslint-disable-next-line */ - const searchOptions = Object.assign({ in: config.searchDefaultInQuick || 'titles' }, options.searchOptions); - const quickSearchResults = options.searchElements.resultEl; - const inputEl = options.searchElements.inputEl; - let oldValue = inputEl.val(); - const filterCategoryEl = quickSearchResults.find('.filter-category'); - - function updateCategoryFilterName() { - if (ajaxify.data.template.category) { - require(['translator'], function (translator) { - translator.translate('[[search:search-in-category, ' + ajaxify.data.name + ']]', function (translated) { - const name = $('
    ').html(translated).text(); - filterCategoryEl.find('.name').text(name); - }); - }); - } - filterCategoryEl.toggleClass('hidden', !ajaxify.data.template.category); - } - - function doSearch() { - require(['search'], function (search) { - /* eslint-disable-next-line */ - options.searchOptions = Object.assign({}, searchOptions); - options.searchOptions.term = inputEl.val(); - updateCategoryFilterName(); - - if (ajaxify.data.template.category) { - if (filterCategoryEl.find('input[type="checkbox"]').is(':checked')) { - options.searchOptions.categories = [ajaxify.data.cid]; - options.searchOptions.searchChildren = true; - } - } - - quickSearchResults.removeClass('hidden').find('.quick-search-results-container').html(''); - quickSearchResults.find('.loading-indicator').removeClass('hidden'); - hooks.fire('action:search.quick.start', options); - options.searchOptions.searchOnly = 1; - search.api(options.searchOptions, function (data) { - quickSearchResults.find('.loading-indicator').addClass('hidden'); - if (options.hideOnNoMatches && !data.posts.length) { - return quickSearchResults.addClass('hidden').find('.quick-search-results-container').html(''); - } - data.posts.forEach(function (p) { - const text = $('
    ' + p.content + '
    ').text(); - const query = inputEl.val().toLowerCase().replace(/^in:topic-\d+/, ''); - const start = Math.max(0, text.toLowerCase().indexOf(query) - 40); - p.snippet = utils.escapeHTML((start > 0 ? '...' : '') + - text.slice(start, start + 80) + - (text.length - start > 80 ? '...' : '')); - }); - app.parseAndTranslate('partials/quick-search-results', data, function (html) { - if (html.length) { - html.find('.timeago').timeago(); - } - quickSearchResults.toggleClass('hidden', !html.length || !inputEl.is(':focus')) - .find('.quick-search-results-container') - .html(html.length ? html : ''); - const highlightEls = quickSearchResults.find( - '.quick-search-results .quick-search-title, .quick-search-results .snippet' - ); - search.highlightMatches(options.searchOptions.term, highlightEls); - hooks.fire('action:search.quick.complete', { - data: data, - options: options, - }); - }); - }); - }); - } - - quickSearchResults.find('.filter-category input[type="checkbox"]').on('change', function () { - inputEl.focus(); - doSearch(); - }); - - inputEl.off('keyup').on('keyup', utils.debounce(function () { - if (inputEl.val().length < 3) { - quickSearchResults.addClass('hidden'); - oldValue = inputEl.val(); - return; - } - if (inputEl.val() === oldValue) { - return; - } - oldValue = inputEl.val(); - if (!inputEl.is(':focus')) { - return quickSearchResults.addClass('hidden'); - } - doSearch(); - }, 500)); - - let mousedownOnResults = false; - quickSearchResults.on('mousedown', function () { - $(window).one('mouseup', function () { - quickSearchResults.addClass('hidden'); - }); - mousedownOnResults = true; - }); - inputEl.on('blur', function () { - if (!inputEl.is(':focus') && !mousedownOnResults && !quickSearchResults.hasClass('hidden')) { - quickSearchResults.addClass('hidden'); - } - }); - - let ajaxified = false; - require(['hooks'], function (hooks) { - hooks.on('action:ajaxify.end', function () { - if (!ajaxify.isCold()) { - ajaxified = true; - } - }); - }); - - inputEl.on('focus', function () { - mousedownOnResults = false; - const query = inputEl.val(); - oldValue = query; - if (query && quickSearchResults.find('#quick-search-results').children().length) { - updateCategoryFilterName(); - if (ajaxified) { - doSearch(); - ajaxified = false; - } else { - quickSearchResults.removeClass('hidden'); - } - inputEl[0].setSelectionRange( - query.startsWith('in:topic') ? query.indexOf(' ') + 1 : 0, - query.length - ); - } - }); - - inputEl.off('refresh').on('refresh', function () { - doSearch(); + console.warn('[deprecated] app.enableTopicSearch is deprecated, please use search.enableQuickSearch(options)'); + require(['search'], function (search) { + search.enableQuickSearch(options); }); }; app.handleSearch = function (searchOptions) { - searchOptions = searchOptions || { in: config.searchDefaultInQuick || 'titles' }; - const searchButton = $('#search-button'); - const searchFields = $('#search-fields'); - const searchInput = $('#search-fields input'); - const quickSearchContainer = $('#quick-search-container'); - - $('#search-form .advanced-search-link').off('mousedown').on('mousedown', function () { - ajaxify.go('/search'); - }); - - $('#search-form').off('submit').on('submit', function () { - searchInput.blur(); - }); - searchInput.off('blur').on('blur', dismissSearch); - searchInput.off('focus'); - - const searchElements = { - inputEl: searchInput, - resultEl: quickSearchContainer, - }; - - app.enableTopicSearch({ - searchOptions: searchOptions, - searchElements: searchElements, - }); - - function dismissSearch() { - setTimeout(function () { - if (!searchInput.is(':focus')) { - searchFields.addClass('hidden'); - searchButton.removeClass('hidden'); - } - }, 200); - } - - searchButton.off('click').on('click', function (e) { - if (!config.loggedIn && !app.user.privileges['search:content']) { - app.alert({ - message: '[[error:search-requires-login]]', - timeout: 3000, - }); - ajaxify.go('login'); - return false; - } - e.stopPropagation(); - - app.prepareSearch(); - return false; - }); - - $('#search-form').off('submit').on('submit', function () { - const input = $(this).find('input'); - require(['search'], function (search) { - const data = search.getSearchPreferences(); - data.term = input.val(); - hooks.fire('action:search.submit', { - searchOptions: data, - searchElements: searchElements, - }); - search.query(data, function () { - input.val(''); - }); - }); - return false; + console.warn('[deprecated] app.handleSearch is deprecated, please use search.init(options)'); + require(['search'], function (search) { + search.init(searchOptions); }); }; app.prepareSearch = function () { - $('#search-fields').removeClass('hidden'); - $('#search-button').addClass('hidden'); - $('#search-fields input').focus(); + console.warn('[deprecated] app.prepareSearch is deprecated, please use search.showAndFocusInput()'); + require(['search'], function (search) { + search.showAndFocusInput(); + }); }; function handleStatusChange() { diff --git a/public/src/client/topic.js b/public/src/client/topic.js index 03bdeb0736..47dfdba236 100644 --- a/public/src/client/topic.js +++ b/public/src/client/topic.js @@ -69,12 +69,12 @@ define('forum/topic', [ function handleTopicSearch() { if (config.topicSearchEnabled) { - require(['mousetrap'], function (mousetrap) { + require(['mousetrap', 'search'], function (mousetrap, search) { mousetrap.bind(['command+f', 'ctrl+f'], function (e) { if (ajaxify.data.template.topic) { e.preventDefault(); $('#search-fields input').val('in:topic-' + ajaxify.data.tid + ' '); - app.prepareSearch(); + search.showAndFocusInput(); } }); }); diff --git a/public/src/client/topic/merge.js b/public/src/client/topic/merge.js index ba716d0738..4264838786 100644 --- a/public/src/client/topic/merge.js +++ b/public/src/client/topic/merge.js @@ -1,7 +1,7 @@ 'use strict'; -define('forum/topic/merge', function () { +define('forum/topic/merge', ['search'], function (search) { const Merge = {}; let modal; let mergeBtn; @@ -30,7 +30,7 @@ define('forum/topic/merge', function () { mergeTopics(mergeBtn); }); - app.enableTopicSearch({ + search.enableQuickSearch({ searchElements: { inputEl: modal.find('.topic-search-input'), resultEl: modal.find('.quick-search-container'), diff --git a/public/src/modules/search.js b/public/src/modules/search.js index cd53fac2e9..1249435c69 100644 --- a/public/src/modules/search.js +++ b/public/src/modules/search.js @@ -1,11 +1,219 @@ 'use strict'; - -define('search', ['navigator', 'translator', 'storage', 'hooks'], function (nav, translator, storage, hooks) { +define('search', ['translator', 'storage', 'hooks'], function (translator, storage, hooks) { const Search = { current: {}, }; + Search.init = function (searchOptions) { + if (!config.searchEnabled) { + return; + } + + searchOptions = searchOptions || { in: config.searchDefaultInQuick || 'titles' }; + const searchButton = $('#search-button'); + const searchFields = $('#search-fields'); + const searchInput = $('#search-fields input'); + const quickSearchContainer = $('#quick-search-container'); + + $('#search-form .advanced-search-link').off('mousedown').on('mousedown', function () { + ajaxify.go('/search'); + }); + + $('#search-form').off('submit').on('submit', function () { + searchInput.blur(); + }); + searchInput.off('blur').on('blur', function dismissSearch() { + setTimeout(function () { + if (!searchInput.is(':focus')) { + searchFields.addClass('hidden'); + searchButton.removeClass('hidden'); + } + }, 200); + }); + searchInput.off('focus'); + + const searchElements = { + inputEl: searchInput, + resultEl: quickSearchContainer, + }; + + Search.enableQuickSearch({ + searchOptions: searchOptions, + searchElements: searchElements, + }); + + searchButton.off('click').on('click', function (e) { + if (!config.loggedIn && !app.user.privileges['search:content']) { + app.alert({ + message: '[[error:search-requires-login]]', + timeout: 3000, + }); + ajaxify.go('login'); + return false; + } + e.stopPropagation(); + + Search.showAndFocusInput(); + return false; + }); + + $('#search-form').off('submit').on('submit', function () { + const input = $(this).find('input'); + const data = Search.getSearchPreferences(); + data.term = input.val(); + hooks.fire('action:search.submit', { + searchOptions: data, + searchElements: searchElements, + }); + Search.query(data, function () { + input.val(''); + }); + + return false; + }); + }; + + Search.enableQuickSearch = function (options) { + if (!config.searchEnabled || !app.user.privileges['search:content']) { + return; + } + + const searchOptions = Object.assign({ in: config.searchDefaultInQuick || 'titles' }, options.searchOptions); + const quickSearchResults = options.searchElements.resultEl; + const inputEl = options.searchElements.inputEl; + let oldValue = inputEl.val(); + const filterCategoryEl = quickSearchResults.find('.filter-category'); + + function updateCategoryFilterName() { + if (ajaxify.data.template.category) { + translator.translate('[[search:search-in-category, ' + ajaxify.data.name + ']]', function (translated) { + const name = $('
    ').html(translated).text(); + filterCategoryEl.find('.name').text(name); + }); + } + filterCategoryEl.toggleClass('hidden', !ajaxify.data.template.category); + } + + function doSearch() { + options.searchOptions = Object.assign({}, searchOptions); + options.searchOptions.term = inputEl.val(); + updateCategoryFilterName(); + + if (ajaxify.data.template.category) { + if (filterCategoryEl.find('input[type="checkbox"]').is(':checked')) { + options.searchOptions.categories = [ajaxify.data.cid]; + options.searchOptions.searchChildren = true; + } + } + + quickSearchResults.removeClass('hidden').find('.quick-search-results-container').html(''); + quickSearchResults.find('.loading-indicator').removeClass('hidden'); + hooks.fire('action:search.quick.start', options); + options.searchOptions.searchOnly = 1; + Search.api(options.searchOptions, function (data) { + quickSearchResults.find('.loading-indicator').addClass('hidden'); + if (options.hideOnNoMatches && !data.posts.length) { + return quickSearchResults.addClass('hidden').find('.quick-search-results-container').html(''); + } + data.posts.forEach(function (p) { + const text = $('
    ' + p.content + '
    ').text(); + const query = inputEl.val().toLowerCase().replace(/^in:topic-\d+/, ''); + const start = Math.max(0, text.toLowerCase().indexOf(query) - 40); + p.snippet = utils.escapeHTML((start > 0 ? '...' : '') + + text.slice(start, start + 80) + + (text.length - start > 80 ? '...' : '')); + }); + app.parseAndTranslate('partials/quick-search-results', data, function (html) { + if (html.length) { + html.find('.timeago').timeago(); + } + quickSearchResults.toggleClass('hidden', !html.length || !inputEl.is(':focus')) + .find('.quick-search-results-container') + .html(html.length ? html : ''); + const highlightEls = quickSearchResults.find( + '.quick-search-results .quick-search-title, .quick-search-results .snippet' + ); + Search.highlightMatches(options.searchOptions.term, highlightEls); + hooks.fire('action:search.quick.complete', { + data: data, + options: options, + }); + }); + }); + } + + quickSearchResults.find('.filter-category input[type="checkbox"]').on('change', function () { + inputEl.focus(); + doSearch(); + }); + + inputEl.off('keyup').on('keyup', utils.debounce(function () { + if (inputEl.val().length < 3) { + quickSearchResults.addClass('hidden'); + oldValue = inputEl.val(); + return; + } + if (inputEl.val() === oldValue) { + return; + } + oldValue = inputEl.val(); + if (!inputEl.is(':focus')) { + return quickSearchResults.addClass('hidden'); + } + doSearch(); + }, 500)); + + let mousedownOnResults = false; + quickSearchResults.on('mousedown', function () { + $(window).one('mouseup', function () { + quickSearchResults.addClass('hidden'); + }); + mousedownOnResults = true; + }); + inputEl.on('blur', function () { + if (!inputEl.is(':focus') && !mousedownOnResults && !quickSearchResults.hasClass('hidden')) { + quickSearchResults.addClass('hidden'); + } + }); + + let ajaxified = false; + hooks.on('action:ajaxify.end', function () { + if (!ajaxify.isCold()) { + ajaxified = true; + } + }); + + inputEl.on('focus', function () { + mousedownOnResults = false; + const query = inputEl.val(); + oldValue = query; + if (query && quickSearchResults.find('#quick-search-results').children().length) { + updateCategoryFilterName(); + if (ajaxified) { + doSearch(); + ajaxified = false; + } else { + quickSearchResults.removeClass('hidden'); + } + inputEl[0].setSelectionRange( + query.startsWith('in:topic') ? query.indexOf(' ') + 1 : 0, + query.length + ); + } + }); + + inputEl.off('refresh').on('refresh', function () { + doSearch(); + }); + }; + + Search.showAndFocusInput = function () { + $('#search-fields').removeClass('hidden'); + $('#search-button').addClass('hidden'); + $('#search-fields input').focus(); + }; + Search.query = function (data, callback) { callback = callback || function () {}; ajaxify.go('search?' + createQueryString(data)); diff --git a/src/meta/js.js b/src/meta/js.js index 7d5fc7fb42..742d27d61d 100644 --- a/src/meta/js.js +++ b/src/meta/js.js @@ -75,6 +75,7 @@ JS.scripts = { 'public/src/modules/storage.js', 'public/src/modules/handleBack.js', 'public/src/modules/messages.js', + 'public/src/modules/search.js', ], admin: [ From f352be63dc5ea89f2e8bd0b9591e7b88c49e05df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 22:20:41 -0500 Subject: [PATCH 382/412] refactor: deprecate app.openChat/newChat use chat.openChat/newChat instead --- public/src/app.js | 68 ++--------------------- public/src/client/account/header.js | 24 ++++----- public/src/client/chats.js | 25 ++++----- public/src/client/chats/search.js | 4 +- public/src/client/flags/detail.js | 8 ++- public/src/client/topic/postTools.js | 5 +- public/src/modules/chat.js | 80 +++++++++++++++++++++++++--- 7 files changed, 112 insertions(+), 102 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index 3374f1b68c..222a2fa6e1 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -295,74 +295,16 @@ app.cacheBuster = null; }; app.openChat = function (roomId, uid) { - if (!app.user.uid) { - return app.alertError('[[error:not-logged-in]]'); - } - + console.warn('[deprecated] app.openChat is deprecated, please use chat.openChat'); require(['chat'], function (chat) { - function loadAndCenter(chatModal) { - chat.load(chatModal.attr('data-uuid')); - chat.center(chatModal); - chat.focusInput(chatModal); - } - - if (chat.modalExists(roomId)) { - loadAndCenter(chat.getModal(roomId)); - } else { - socket.emit('modules.chats.loadRoom', { roomId: roomId, uid: uid || app.user.uid }, function (err, roomData) { - if (err) { - return app.alertError(err.message); - } - roomData.users = roomData.users.filter(function (user) { - return user && parseInt(user.uid, 10) !== parseInt(app.user.uid, 10); - }); - roomData.uid = uid || app.user.uid; - roomData.isSelf = true; - chat.createModal(roomData, loadAndCenter); - }); - } + chat.openChat(roomId, uid); }); }; app.newChat = function (touid, callback) { - function createChat() { - socket.emit('modules.chats.newRoom', { touid: touid }, function (err, roomId) { - if (err) { - return app.alertError(err.message); - } - - if (!ajaxify.data.template.chats) { - app.openChat(roomId); - } else { - ajaxify.go('chats/' + roomId); - } - - callback(false, roomId); - }); - } - - callback = callback || function () { }; - if (!app.user.uid) { - return app.alertError('[[error:not-logged-in]]'); - } - - if (parseInt(touid, 10) === parseInt(app.user.uid, 10)) { - return app.alertError('[[error:cant-chat-with-yourself]]'); - } - socket.emit('modules.chats.isDnD', touid, function (err, isDnD) { - if (err) { - return app.alertError(err.message); - } - if (!isDnD) { - return createChat(); - } - require(['bootbox'], function (bootbox) { - bootbox.confirm('[[modules:chat.confirm-chat-with-dnd-user]]', function (ok) { - if (ok) { - createChat(); - } - }); - }); + console.warn('[deprecated] app.newChat is deprecated, please use chat.newChat'); + require(['chat'], function (chat) { + chat.newChat(touid, callback); }); }; diff --git a/public/src/client/account/header.js b/public/src/client/account/header.js index e46bded766..5bb46becaf 100644 --- a/public/src/client/account/header.js +++ b/public/src/client/account/header.js @@ -32,21 +32,19 @@ define('forum/account/header', [ toggleFollow('unfollow'); }); - components.get('account/chat').on('click', function () { - socket.emit('modules.chats.hasPrivateChat', ajaxify.data.uid, function (err, roomId) { - if (err) { - return app.alertError(err.message); - } - if (roomId) { - app.openChat(roomId); - } else { - app.newChat(ajaxify.data.uid); - } - }); + components.get('account/chat').on('click', async function () { + const roomId = await socket.emit('modules.chats.hasPrivateChat', ajaxify.data.uid); + const chat = await app.require('chat'); + if (roomId) { + chat.openChat(roomId); + } else { + chat.newChat(ajaxify.data.uid); + } }); - components.get('account/new-chat').on('click', function () { - app.newChat(ajaxify.data.uid, function () { + components.get('account/new-chat').on('click', async function () { + const chat = await app.require('chat'); + chat.newChat(ajaxify.data.uid, function () { components.get('account/chat').parent().removeClass('hidden'); }); }); diff --git a/public/src/client/chats.js b/public/src/client/chats.js index 45b958e4f1..c3fc8ff560 100644 --- a/public/src/client/chats.js +++ b/public/src/client/chats.js @@ -8,14 +8,14 @@ define('forum/chats', [ 'forum/chats/recent', 'forum/chats/search', 'forum/chats/messages', - 'benchpress', 'composer/autocomplete', 'hooks', 'bootbox', + 'chat', ], function ( components, translator, mousetrap, - recentChats, search, messages, Benchpress, - autocomplete, hooks, bootbox + recentChats, search, messages, + autocomplete, hooks, bootbox, chatModule ) { const Chats = { initialised: false, @@ -93,11 +93,11 @@ define('forum/chats', [ if (app.previousUrl && app.previousUrl.match(/chats/)) { ajaxify.go('user/' + ajaxify.data.userslug + '/chats', function () { - app.openChat(roomId, ajaxify.data.uid); + chatModule.openChat(roomId, ajaxify.data.uid); }, true); } else { window.history.go(-1); - app.openChat(roomId, ajaxify.data.uid); + chatModule.openChat(roomId, ajaxify.data.uid); } $(window).one('action:chat.loaded', function () { @@ -294,9 +294,7 @@ define('forum/chats', [ // Return user to chats page. If modal, close modal. const modal = buttonEl.parents('.chat-modal'); if (modal.length) { - require(['chat'], function (chatLib) { - chatLib.close(modal); - }); + chatModule.close(modal); } else { ajaxify.go('chats'); } @@ -408,12 +406,11 @@ define('forum/chats', [ } else { el.remove(); } - require(['chat'], function (chat) { - const modal = chat.getModal(roomId); - if (modal.length) { - chat.close(modal); - } - }); + + const modal = chatModule.getModal(roomId); + if (modal.length) { + chatModule.close(modal); + } }); }; diff --git a/public/src/client/chats/search.js b/public/src/client/chats/search.js index 82bfcba8cc..fac37f908e 100644 --- a/public/src/client/chats/search.js +++ b/public/src/client/chats/search.js @@ -69,7 +69,9 @@ define('forum/chats/search', ['components', 'api'], function (components, api) { chats.switchChat(roomId); }); } else { - app.newChat(userObj.uid); + require(['chat'], function (chat) { + chat.newChat(userObj.uid); + }); } }); }); diff --git a/public/src/client/flags/detail.js b/public/src/client/flags/detail.js index 81b1592a73..aa8ef07c21 100644 --- a/public/src/client/flags/detail.js +++ b/public/src/client/flags/detail.js @@ -1,6 +1,8 @@ 'use strict'; -define('forum/flags/detail', ['forum/flags/list', 'components', 'translator', 'benchpress', 'forum/account/header', 'accounts/delete', 'api', 'bootbox'], function (FlagsList, components, translator, Benchpress, AccountHeader, AccountsDelete, api, bootbox) { +define('forum/flags/detail', [ + 'components', 'translator', 'benchpress', 'forum/account/header', 'accounts/delete', 'api', 'bootbox', +], function (components, translator, Benchpress, AccountHeader, AccountsDelete, api, bootbox) { const Detail = {}; Detail.init = function () { @@ -59,7 +61,9 @@ define('forum/flags/detail', ['forum/flags/list', 'components', 'translator', 'b break; } case 'chat': - app.newChat(uid); + require(['chat'], function (chat) { + chat.newChat(uid); + }); break; case 'ban': diff --git a/public/src/client/topic/postTools.js b/public/src/client/topic/postTools.js index 8dab0b0874..36c752fa9f 100644 --- a/public/src/client/topic/postTools.js +++ b/public/src/client/topic/postTools.js @@ -420,8 +420,9 @@ define('forum/topic/postTools', [ function openChat(button) { const post = button.parents('[data-pid]'); - - app.newChat(post.attr('data-uid')); + require(['chat'], function (chat) { + chat.newChat(post.attr('data-uid')); + }); button.parents('.btn-group').find('.dropdown-toggle').click(); return false; } diff --git a/public/src/modules/chat.js b/public/src/modules/chat.js index 94e4764ec8..d57386040a 100644 --- a/public/src/modules/chat.js +++ b/public/src/modules/chat.js @@ -1,14 +1,80 @@ 'use strict'; define('chat', [ - 'components', - 'taskbar', - 'translator', - 'hooks', -], function (components, taskbar, translator, hooks) { + 'components', 'taskbar', 'translator', 'hooks', 'bootbox', +], function (components, taskbar, translator, hooks, bootbox) { const module = {}; let newMessage = false; + module.openChat = function (roomId, uid) { + if (!app.user.uid) { + return app.alertError('[[error:not-logged-in]]'); + } + + function loadAndCenter(chatModal) { + module.load(chatModal.attr('data-uuid')); + module.center(chatModal); + module.focusInput(chatModal); + } + + if (module.modalExists(roomId)) { + loadAndCenter(module.getModal(roomId)); + } else { + socket.emit('modules.chats.loadRoom', { roomId: roomId, uid: uid || app.user.uid }, function (err, roomData) { + if (err) { + return app.alertError(err.message); + } + roomData.users = roomData.users.filter(function (user) { + return user && parseInt(user.uid, 10) !== parseInt(app.user.uid, 10); + }); + roomData.uid = uid || app.user.uid; + roomData.isSelf = true; + module.createModal(roomData, loadAndCenter); + }); + } + }; + + module.newChat = function (touid, callback) { + function createChat() { + socket.emit('modules.chats.newRoom', { touid: touid }, function (err, roomId) { + if (err) { + return app.alertError(err.message); + } + + if (!ajaxify.data.template.chats) { + module.openChat(roomId); + } else { + ajaxify.go('chats/' + roomId); + } + + callback(null, roomId); + }); + } + + callback = callback || function () { }; + if (!app.user.uid) { + return app.alertError('[[error:not-logged-in]]'); + } + + if (parseInt(touid, 10) === parseInt(app.user.uid, 10)) { + return app.alertError('[[error:cant-chat-with-yourself]]'); + } + socket.emit('modules.chats.isDnD', touid, function (err, isDnD) { + if (err) { + return app.alertError(err.message); + } + if (!isDnD) { + return createChat(); + } + + bootbox.confirm('[[modules:chat.confirm-chat-with-dnd-user]]', function (ok) { + if (ok) { + createChat(); + } + }); + }); + }; + module.loadChatsDropdown = function (chatsListEl) { socket.emit('modules.chats.getRecentChats', { uid: app.user.uid, @@ -37,7 +103,7 @@ define('chat', [ } const roomId = $(this).attr('data-roomid'); if (!ajaxify.currentPage.match(/^chats\//)) { - app.openChat(roomId); + module.openChat(roomId); } else { ajaxify.go('user/' + app.user.userslug + '/chats/' + roomId); } @@ -206,7 +272,7 @@ define('chat', [ module.minimize(uuid); }); - chatModal.on('click', ':not(.close)', function () { + chatModal.on('mouseup', function () { taskbar.updateActive(chatModal.attr('data-uuid')); if (dragged) { From e3f5b706a513c01152d617011730419af3a450f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 22:36:10 -0500 Subject: [PATCH 383/412] test: show body when test fails --- test/controllers.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/controllers.js b/test/controllers.js index 452b43d302..8a27c80d3c 100644 --- a/test/controllers.js +++ b/test/controllers.js @@ -379,7 +379,7 @@ describe('Controllers', () => { resolveWithFullResponse: true, }); - assert(res.body.errors.includes('[[error:invalid-email]]')); + assert(res.body.errors.includes('[[error:invalid-email]]'), res.body); }); it('gdpr interstitial should still apply if email requirement is disabled', async () => { From 654c8e61487b0fe04ab0f5e7aede60fb53e1b998 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 8 Nov 2021 22:37:57 -0500 Subject: [PATCH 384/412] fix(deps): update dependency nodebb-plugin-composer-default to v7.0.13 (#9988) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index db67e3b86b..0ce556f6a8 100644 --- a/install/package.json +++ b/install/package.json @@ -84,7 +84,7 @@ "multiparty": "4.2.2", "@nodebb/bootswatch": "3.4.2", "nconf": "^0.11.2", - "nodebb-plugin-composer-default": "7.0.12", + "nodebb-plugin-composer-default": "7.0.13", "nodebb-plugin-dbsearch": "5.1.0", "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", From 619034484fe5f41cd8d3829de10aaba316fddd65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 22:48:02 -0500 Subject: [PATCH 385/412] refactor: simpler rejoin remove pointless app.cacheBuster = null --- public/src/app.js | 1 - public/src/sockets.js | 34 ++++------------------------------ 2 files changed, 4 insertions(+), 31 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index 222a2fa6e1..7d89a18002 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -7,7 +7,6 @@ app.isFocused = true; app.currentRoom = null; app.widgets = {}; app.flags = {}; -app.cacheBuster = null; (function () { let appLoaded = false; diff --git a/public/src/sockets.js b/public/src/sockets.js index c4763b28d5..94bc09dab0 100644 --- a/public/src/sockets.js +++ b/public/src/sockets.js @@ -172,37 +172,11 @@ socket = window.socket; } function reJoinCurrentRoom() { - const url_parts = window.location.pathname.slice(config.relative_path.length).split('/').slice(1); - let room; - - switch (url_parts[0]) { - case 'user': - room = 'user/' + (ajaxify.data ? ajaxify.data.theirid : 0); - break; - case 'topic': - room = 'topic_' + url_parts[1]; - break; - case 'category': - room = 'category_' + url_parts[1]; - break; - case 'recent': - room = 'recent_topics'; - break; - case 'unread': - room = 'unread_topics'; - break; - case 'popular': - room = 'popular_topics'; - break; - case 'admin': - room = 'admin'; - break; - case 'categories': - room = 'categories'; - break; + if (app.currentRoom) { + const current = app.currentRoom; + app.currentRoom = ''; + app.enterRoom(current); } - app.currentRoom = ''; - app.enterRoom(room); } function onReconnecting() { From ef02bdc4671a9dddf9f7378fcd3fd53124b0b730 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 8 Nov 2021 22:50:05 -0500 Subject: [PATCH 386/412] fix(deps): update dependency nodebb-plugin-composer-default to v7.0.14 (#9989) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 0ce556f6a8..06adaf3017 100644 --- a/install/package.json +++ b/install/package.json @@ -84,7 +84,7 @@ "multiparty": "4.2.2", "@nodebb/bootswatch": "3.4.2", "nconf": "^0.11.2", - "nodebb-plugin-composer-default": "7.0.13", + "nodebb-plugin-composer-default": "7.0.14", "nodebb-plugin-dbsearch": "5.1.0", "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", From cf30876fbf9c2a1c2346aa138f6db9ce1f6fd367 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 8 Nov 2021 22:50:11 -0500 Subject: [PATCH 387/412] fix(deps): update dependency nodebb-theme-slick to v1.4.16 (#9990) Co-authored-by: Renovate Bot --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 06adaf3017..31f91d4c02 100644 --- a/install/package.json +++ b/install/package.json @@ -94,7 +94,7 @@ "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.3.1", "nodebb-theme-persona": "11.2.21", - "nodebb-theme-slick": "1.4.15", + "nodebb-theme-slick": "1.4.16", "nodebb-theme-vanilla": "12.1.9", "nodebb-widget-essentials": "5.0.4", "nodemailer": "^6.5.0", From 8b4510cc7088d135d7fdeeb1be006f9e98ed87f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 8 Nov 2021 23:28:26 -0500 Subject: [PATCH 388/412] refactor: deprecate app.logout use logout module instead move header related code out of app.js --- public/src/admin/admin.js | 4 +- public/src/app.js | 88 +++---------------------------- public/src/client/account/edit.js | 4 +- public/src/client/header.js | 71 +++++++++++++++++++++++++ public/src/modules/logout.js | 28 ++++++++++ public/src/sockets.js | 8 +-- src/meta/js.js | 1 + 7 files changed, 117 insertions(+), 87 deletions(-) create mode 100644 public/src/client/header.js create mode 100644 public/src/modules/logout.js diff --git a/public/src/admin/admin.js b/public/src/admin/admin.js index ebb697f42d..a91572c009 100644 --- a/public/src/admin/admin.js +++ b/public/src/admin/admin.js @@ -54,7 +54,9 @@ } $('[component="logout"]').on('click', function () { - app.logout(); + require(['logout'], function (logout) { + logout(); + }); return false; }); diff --git a/public/src/app.js b/public/src/app.js index 7d89a18002..f486c8f804 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -72,24 +72,15 @@ app.flags = {}; app.handleEarlyClicks(); app.load = function () { - handleStatusChange(); - $('body').on('click', '#new_topic', function (e) { e.preventDefault(); app.newTopic(); }); - $('#header-menu .container').on('click', '[component="user/logout"]', function () { - app.logout(); - return false; - }); - Visibility.change(function (event, state) { app.isFocused = state === 'visible'; }); - createHeaderTooltips(); - registerServiceWorker(); require([ @@ -100,12 +91,10 @@ app.flags = {}; 'messages', 'search', 'forum/unread', - 'forum/header/notifications', - 'forum/header/chat', + 'forum/header', 'timeago/jquery.timeago', - ], function (taskbar, helpers, pagination, translator, messages, search, unread, notifications, chat) { - notifications.prepareDOM(); - chat.prepareDOM(); + ], function (taskbar, helpers, pagination, translator, messages, search, unread, header) { + header.prepareDOM(); translator.prepareDOM(); taskbar.init(); helpers.register(); @@ -144,29 +133,10 @@ app.flags = {}; }; app.logout = function (redirect) { - redirect = redirect === undefined ? true : redirect; - hooks.fire('action:app.logout'); - - $.ajax(config.relative_path + '/logout', { - type: 'POST', - headers: { - 'x-csrf-token': config.csrf_token, - }, - beforeSend: function () { - app.flags._logout = true; - }, - success: function (data) { - hooks.fire('action:app.loggedOut', data); - if (redirect) { - if (data.next) { - window.location.href = data.next; - } else { - window.location.reload(); - } - } - }, + console.warn('[deprecated] app.logout is deprecated, please use logout module directly'); + require(['logout'], function (logout) { + logout(redirect); }); - return false; }; app.alert = function (params) { @@ -314,34 +284,6 @@ app.flags = {}; }); }; - function createHeaderTooltips() { - const env = utils.findBootstrapEnvironment(); - if (env === 'xs' || env === 'sm' || isTouchDevice) { - return; - } - $('#header-menu li a[title]').each(function () { - $(this).tooltip({ - placement: 'bottom', - trigger: 'hover', - title: $(this).attr('title'), - }); - }); - - - $('#search-form').tooltip({ - placement: 'bottom', - trigger: 'hover', - title: $('#search-button i').attr('title'), - }); - - - $('#user_dropdown').tooltip({ - placement: 'bottom', - trigger: 'hover', - title: $('#user_dropdown').attr('title'), - }); - } - app.enableTopicSearch = function (options) { console.warn('[deprecated] app.enableTopicSearch is deprecated, please use search.enableQuickSearch(options)'); require(['search'], function (search) { @@ -363,24 +305,6 @@ app.flags = {}; }); }; - function handleStatusChange() { - $('[component="header/usercontrol"] [data-status]').off('click').on('click', function (e) { - const status = $(this).attr('data-status'); - socket.emit('user.setStatus', status, function (err) { - if (err) { - return app.alertError(err.message); - } - $('[data-uid="' + app.user.uid + '"] [component="user/status"], [component="header/profilelink"] [component="user/status"]') - .removeClass('away online dnd offline') - .addClass(status); - $('[component="header/usercontrol"] [data-status]').each(function () { - $(this).find('span').toggleClass('bold', $(this).attr('data-status') === status); - }); - app.user.status = status; - }); - e.preventDefault(); - }); - } app.updateUserStatus = function (el, status) { if (!el.length) { diff --git a/public/src/client/account/edit.js b/public/src/client/account/edit.js index 6a001084fc..6c69eb6dba 100644 --- a/public/src/client/account/edit.js +++ b/public/src/client/account/edit.js @@ -89,7 +89,9 @@ define('forum/account/edit', [ } confirmBtn.html(''); - app.logout(); + require(['logout'], function (logout) { + logout(); + }); }); return false; diff --git a/public/src/client/header.js b/public/src/client/header.js new file mode 100644 index 0000000000..c6dfe9edb2 --- /dev/null +++ b/public/src/client/header.js @@ -0,0 +1,71 @@ +'use strict'; + +define('forum/header', ['forum/header/notifications', 'forum/header/chat'], function (notifications, chat) { + const module = {}; + + module.prepareDOM = function () { + notifications.prepareDOM(); + chat.prepareDOM(); + handleStatusChange(); + createHeaderTooltips(); + handleLogout(); + }; + + function handleStatusChange() { + $('[component="header/usercontrol"] [data-status]').off('click').on('click', function (e) { + const status = $(this).attr('data-status'); + socket.emit('user.setStatus', status, function (err) { + if (err) { + return app.alertError(err.message); + } + $('[data-uid="' + app.user.uid + '"] [component="user/status"], [component="header/profilelink"] [component="user/status"]') + .removeClass('away online dnd offline') + .addClass(status); + $('[component="header/usercontrol"] [data-status]').each(function () { + $(this).find('span').toggleClass('bold', $(this).attr('data-status') === status); + }); + app.user.status = status; + }); + e.preventDefault(); + }); + } + + function createHeaderTooltips() { + const env = utils.findBootstrapEnvironment(); + if (env === 'xs' || env === 'sm' || utils.isTouchDevice()) { + return; + } + $('#header-menu li a[title]').each(function () { + $(this).tooltip({ + placement: 'bottom', + trigger: 'hover', + title: $(this).attr('title'), + }); + }); + + + $('#search-form').tooltip({ + placement: 'bottom', + trigger: 'hover', + title: $('#search-button i').attr('title'), + }); + + + $('#user_dropdown').tooltip({ + placement: 'bottom', + trigger: 'hover', + title: $('#user_dropdown').attr('title'), + }); + } + + function handleLogout() { + $('#header-menu .container').on('click', '[component="user/logout"]', function () { + require(['logout'], function (logout) { + logout(); + }); + return false; + }); + } + + return module; +}); diff --git a/public/src/modules/logout.js b/public/src/modules/logout.js new file mode 100644 index 0000000000..400d5c25e1 --- /dev/null +++ b/public/src/modules/logout.js @@ -0,0 +1,28 @@ +'use strict'; + +define('logout', ['hooks'], function (hooks) { + return function logout(redirect) { + redirect = redirect === undefined ? true : redirect; + hooks.fire('action:app.logout'); + + $.ajax(config.relative_path + '/logout', { + type: 'POST', + headers: { + 'x-csrf-token': config.csrf_token, + }, + beforeSend: function () { + app.flags._logout = true; + }, + success: function (data) { + hooks.fire('action:app.loggedOut', data); + if (redirect) { + if (data.next) { + window.location.href = data.next; + } else { + window.location.reload(); + } + } + }, + }); + }; +}); diff --git a/public/src/sockets.js b/public/src/sockets.js index 94bc09dab0..5403717009 100644 --- a/public/src/sockets.js +++ b/public/src/sockets.js @@ -94,7 +94,9 @@ socket = window.socket; socket.on('event:banned', onEventBanned); socket.on('event:unbanned', onEventUnbanned); socket.on('event:logout', function () { - app.logout(); + require(['logout'], function (logout) { + logout(); + }); }); socket.on('event:alert', function (params) { app.alert(params); @@ -128,8 +130,8 @@ socket = window.socket; function handleInvalidSession() { socket.disconnect(); - app.logout(false); - require(['messages'], function (messages) { + require(['messages', 'logout'], function (messages, logout) { + logout(false); messages.showInvalidSession(); }); } diff --git a/src/meta/js.js b/src/meta/js.js index 742d27d61d..6901932869 100644 --- a/src/meta/js.js +++ b/src/meta/js.js @@ -41,6 +41,7 @@ JS.scripts = { // files listed below are only available client-side, or are bundled in to reduce # of network requests on cold load rjs: [ + 'public/src/client/header.js', 'public/src/client/header/chat.js', 'public/src/client/header/notifications.js', 'public/src/client/infinitescroll.js', From 1719bff89cb145c540294a93481518fbed22fce3 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Tue, 9 Nov 2021 10:39:45 -0500 Subject: [PATCH 389/412] feat: use auto-generated meta and link tags in ACP, closes #9991 --- src/middleware/admin.js | 3 +++ src/views/admin/header.tpl | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/middleware/admin.js b/src/middleware/admin.js index 8fe54e6a10..67408905ca 100644 --- a/src/middleware/admin.js +++ b/src/middleware/admin.js @@ -40,6 +40,7 @@ middleware.renderHeader = async (req, res, data) => { configs: meta.configs.list(), latestVersion: getLatestVersion(), privileges: privileges.admin.get(req.uid), + tags: meta.tags.parse(req, {}, [], []), }); const { userData } = results; @@ -61,6 +62,8 @@ middleware.renderHeader = async (req, res, data) => { configJSON: jsesc(JSON.stringify(res.locals.config), { isScriptContext: true }), relative_path: res.locals.config.relative_path, adminConfigJSON: encodeURIComponent(JSON.stringify(results.configs)), + metaTags: results.tags.meta, + linkTags: results.tags.link, user: userData, userJSON: jsesc(JSON.stringify(userData), { isScriptContext: true }), plugins: results.custom_header.plugins, diff --git a/src/views/admin/header.tpl b/src/views/admin/header.tpl index a0f5fef1e3..ee81bfeb2d 100644 --- a/src/views/admin/header.tpl +++ b/src/views/admin/header.tpl @@ -2,8 +2,9 @@ {title} - + {{{each metaTags}}}{function.buildMetaTag}{{{end}}} + {{{each linkTags}}}{function.buildLinkTag}{{{end}}} From 61d1f5650023e0cac7953fd5db1cf311de33558d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 9 Nov 2021 10:51:44 -0500 Subject: [PATCH 390/412] test: socket.emit doesnt exist in tests --- src/socket.io/admin/user.js | 6 ++++-- src/socket.io/index.js | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/socket.io/admin/user.js b/src/socket.io/admin/user.js index e813053137..abb12cceed 100644 --- a/src/socket.io/admin/user.js +++ b/src/socket.io/admin/user.js @@ -172,7 +172,9 @@ User.exportUsersCSV = async function (socket) { setTimeout(async () => { try { await user.exportUsersCSV(); - socket.emit('event:export-users-csv'); + if (socket.emit) { + socket.emit('event:export-users-csv'); + } const notifications = require('../../notifications'); const n = await notifications.create({ bodyShort: '[[notifications:users-csv-exported]]', @@ -182,7 +184,7 @@ User.exportUsersCSV = async function (socket) { }); await notifications.push(n, [socket.uid]); } catch (err) { - winston.error(err); + winston.error(err.stack); } }, 0); }; diff --git a/src/socket.io/index.js b/src/socket.io/index.js index 4d88ed51ee..4dd74db26f 100644 --- a/src/socket.io/index.js +++ b/src/socket.io/index.js @@ -253,7 +253,7 @@ Sockets.getCountInRoom = function (room) { }; Sockets.warnDeprecated = (socket, replacement) => { - if (socket.previousEvents) { + if (socket.previousEvents && socket.emit) { socket.emit('event:deprecated_call', { eventName: socket.previousEvents[socket.previousEvents.length - 1], replacement: replacement, From ae64b9f4958ef98af43a28d0cebe436be0758232 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 9 Nov 2021 11:05:03 -0500 Subject: [PATCH 391/412] test: add another assert for random failing test --- test/controllers.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/controllers.js b/test/controllers.js index 8a27c80d3c..4ac33196d5 100644 --- a/test/controllers.js +++ b/test/controllers.js @@ -378,7 +378,7 @@ describe('Controllers', () => { json: true, resolveWithFullResponse: true, }); - + assert(res.body.errors.length, res.body); assert(res.body.errors.includes('[[error:invalid-email]]'), res.body); }); From 0428912c6d5c626b078469d856bdd7d9cfbef660 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 9 Nov 2021 13:34:59 -0500 Subject: [PATCH 392/412] refactor: deprecate app.alert functions user alerts module directly --- public/src/app.js | 44 ++++++++++++------------------------ public/src/modules/alerts.js | 36 +++++++++++++++++++++++++---- 2 files changed, 47 insertions(+), 33 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index f486c8f804..f1118e3505 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -14,11 +14,6 @@ app.flags = {}; app.cacheBuster = config['cache-buster']; - let hooks; - require(['hooks'], function (_hooks) { - hooks = _hooks; - }); - $(document).ready(function () { ajaxify.parseData(); app.load(); @@ -92,8 +87,9 @@ app.flags = {}; 'search', 'forum/unread', 'forum/header', + 'hooks', 'timeago/jquery.timeago', - ], function (taskbar, helpers, pagination, translator, messages, search, unread, header) { + ], function (taskbar, helpers, pagination, translator, messages, search, unread, header, hooks) { header.prepareDOM(); translator.prepareDOM(); taskbar.init(); @@ -140,42 +136,30 @@ app.flags = {}; }; app.alert = function (params) { + console.warn('[deprecated] app.alert is deprecated, please use alerts.alert'); require(['alerts'], function (alerts) { alerts.alert(params); }); }; app.removeAlert = function (id) { + console.warn('[deprecated] app.removeAlert is deprecated, please use alerts.remove'); require(['alerts'], function (alerts) { alerts.remove(id); }); }; app.alertSuccess = function (message, timeout) { - app.alert({ - alert_id: utils.generateUUID(), - title: '[[global:alert.success]]', - message: message, - type: 'success', - timeout: timeout || 5000, + console.warn('[deprecated] app.alertSuccess is deprecated, please use alerts.success'); + require(['alerts'], function (alerts) { + alerts.success(message, timeout); }); }; app.alertError = function (message, timeout) { - message = (message && message.message) || message; - - if (message === '[[error:revalidate-failure]]') { - socket.disconnect(); - app.reconnect(); - return; - } - - app.alert({ - alert_id: utils.generateUUID(), - title: '[[global:alert.error]]', - message: message, - type: 'danger', - timeout: timeout || 10000, + console.warn('[deprecated] app.alertError is deprecated, please use alerts.error'); + require(['alerts'], function (alerts) { + alerts.error(message, timeout); }); }; @@ -322,9 +306,11 @@ app.flags = {}; }; app.newTopic = function (cid, tags) { - hooks.fire('action:composer.topic.new', { - cid: cid || ajaxify.data.cid || 0, - tags: tags || (ajaxify.data.tag ? [ajaxify.data.tag] : []), + require(['hooks'], function (hooks) { + hooks.fire('action:composer.topic.new', { + cid: cid || ajaxify.data.cid || 0, + tags: tags || (ajaxify.data.tag ? [ajaxify.data.tag] : []), + }); }); }; diff --git a/public/src/modules/alerts.js b/public/src/modules/alerts.js index 5bbd40bf3c..da0fc006e7 100644 --- a/public/src/modules/alerts.js +++ b/public/src/modules/alerts.js @@ -18,6 +18,38 @@ define('alerts', ['translator', 'components', 'hooks'], function (translator, co } }; + module.success = function (message, timeout) { + module.alert({ + alert_id: utils.generateUUID(), + title: '[[global:alert.success]]', + message: message, + type: 'success', + timeout: timeout || 5000, + }); + }; + + module.error = function (message, timeout) { + message = (message && message.message) || message; + + if (message === '[[error:revalidate-failure]]') { + socket.disconnect(); + app.reconnect(); + return; + } + + module.alert({ + alert_id: utils.generateUUID(), + title: '[[global:alert.error]]', + message: message, + type: 'danger', + timeout: timeout || 10000, + }); + }; + + module.remove = function (id) { + $('#alert_button_' + id).remove(); + }; + function createNew(params) { app.parseAndTranslate('alert', params, function (html) { let alert = $('#' + params.alert_id); @@ -56,10 +88,6 @@ define('alerts', ['translator', 'components', 'hooks'], function (translator, co }); } - module.remove = function (id) { - $('#alert_button_' + id).remove(); - }; - function updateAlert(alert, params) { alert.find('strong').html(params.title); alert.find('p').html(params.message); From 96f13e4f5d127a4362d1e86f6f7839fd3865a363 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 9 Nov 2021 19:29:29 -0500 Subject: [PATCH 393/412] feat: #9992, hooks.one --- public/src/modules/hooks.js | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/public/src/modules/hooks.js b/public/src/modules/hooks.js index c474d9b15f..f324bc706e 100644 --- a/public/src/modules/hooks.js +++ b/public/src/modules/hooks.js @@ -4,6 +4,7 @@ define('hooks', [], () => { const Hooks = { loaded: {}, temporary: new Set(), + runOnce: new Set(), deprecated: { 'action:script.load': 'filter:script.load', // 👋 @ 1.18.0 'action:category.loaded': 'action:topics.loaded', // 👋 @ 1.19.0 @@ -32,6 +33,10 @@ define('hooks', [], () => { console.debug(`[hooks] Registered ${hookName}`, method); }; Hooks.on = Hooks.register; + Hooks.one = (hookName, method) => { + Hooks.register(hookName, method); + Hooks.runOnce.add({ hookName, method }); + }; // registerPage/onPage takes care of unregistering the listener on ajaxify Hooks.registerPage = (hookName, method) => { @@ -110,17 +115,27 @@ define('hooks', [], () => { Hooks.fire = (hookName, data) => { const type = hookName.split(':').shift(); - + let result; switch (type) { case 'filter': - return _fireFilterHook(hookName, data); + result = _fireFilterHook(hookName, data); + break; case 'action': - return _fireActionHook(hookName, data); + result = _fireActionHook(hookName, data); + break; case 'static': - return _fireStaticHook(hookName, data); + result = _fireStaticHook(hookName, data); + break; } + Hooks.runOnce.forEach((pair) => { + if (pair.hookName === hookName) { + Hooks.unregister(hookName, pair.method); + Hooks.runOnce.delete(pair); + } + }); + return result; }; return Hooks; From 41c3eb8298d30a85e6d885e048a91adf37fa60bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 9 Nov 2021 19:38:35 -0500 Subject: [PATCH 394/412] refactor: shorter require --- public/src/app.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/public/src/app.js b/public/src/app.js index f1118e3505..6154c8b323 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -115,10 +115,9 @@ app.flags = {}; }; app.require = async (modules) => { // allows you to await require.js modules - let single = false; - if (!Array.isArray(modules)) { + const single = !Array.isArray(modules); + if (single) { modules = [modules]; - single = true; } return new Promise((resolve, reject) => { From 975cb5126271105736b85da64af759ae6773290d Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 10 Nov 2021 09:07:28 +0000 Subject: [PATCH 395/412] Latest translations and fallbacks --- .../language/he/admin/settings/advanced.json | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/public/language/he/admin/settings/advanced.json b/public/language/he/admin/settings/advanced.json index 2f71a62b2a..621a94adb3 100644 --- a/public/language/he/admin/settings/advanced.json +++ b/public/language/he/admin/settings/advanced.json @@ -5,14 +5,14 @@ "maintenance-mode.message": "הודעת תחזוקה", "headers": "כותרות", "headers.allow-from": "הגדר ALLOW-FROM למקם NodeBB ב- iFrame", - "headers.csp-frame-ancestors": "Set Content-Security-Policy frame-ancestors header to Place NodeBB in an iFrame", - "headers.csp-frame-ancestors-help": "'none', 'self'(default) or list of URIs to allow.", + "headers.csp-frame-ancestors": "הגדר את מדיניות האבטחה (Content-Security-Policy) עבור ההטמעה (frame-ancestors) של NodeBB בתוך Iframe", + "headers.csp-frame-ancestors-help": "בחר מילים שמורות כמו 'none' (ללא) 'self' (רק מהאתר שלי) או כתובת מלאה של אתר חיצוני", "headers.powered-by": "התאם אישית את הכותרת \"מופעל ע\"י\" הברירת מחדל של נודביבי", - "headers.acao": "Access-Control-Allow-Origin", - "headers.acao-regex": "Access-Control-Allow-Origin Regular Expression", + "headers.acao": "אתרים הרשאים לקרוא לאתר זה (Access-Control-Allow-Origin)", + "headers.acao-regex": "תבנית טקסט (Regex) עבור אתרים הרשאים לקרוא לאתר זה (Access-Control-Allow-Origin)", "headers.acao-help": "כדי למנוע גישה לכל האתרים, השאר ריק", - "headers.acao-regex-help": "Enter regular expressions here to match dynamic origins. To deny access to all sites, leave empty", - "headers.acac": "Access-Control-Allow-Credentials", + "headers.acao-regex-help": "הכנס תבנית טקסט (Regex) כאן כדי לאפשר קריאה דינאמית מאתרים חיצוניים. אם ברצונך לחסום כל גישה חיצונית, השאר ריק.", + "headers.acac": "אתרים אשר אל בקשות אליהם, יתווספו גם נתוני כניסה כגוןCookie וכו'. ( Access-Control-Allow-Credentials)", "headers.acam": "Access-Control-Allow-Methods", "headers.acah": "Access-Control-Allow-Headers", "hsts": "Strict Transport Security", @@ -26,13 +26,13 @@ "traffic.enable": "Enable Traffic Management", "traffic.event-lag": "Event Loop Lag Threshold (in milliseconds)", "traffic.event-lag-help": "Lowering this value decreases wait times for page loads, but will also show the \"excessive load\" message to more users. (Restart required)", - "traffic.lag-check-interval": "Check Interval (in milliseconds)", + "traffic.lag-check-interval": "מרווח זמן בין בדיקות (במילישניות)", "traffic.lag-check-interval-help": "Lowering this value causes NodeBB to become more sensitive to spikes in load, but may also cause the check to become too sensitive. (Restart required)", - "sockets.settings": "WebSocket Settings", - "sockets.max-attempts": "Max Reconnection Attempts", + "sockets.settings": "הגדרות חיבור WebSocket", + "sockets.max-attempts": "מקסימום מספר נסיונות חיבור מחדש", "sockets.default-placeholder": "ברירת מחדל: %1", - "sockets.delay": "Reconnection Delay", + "sockets.delay": "זמן השעייה בן נסיונות חיבור מחדש", "analytics.settings": "Analytics Settings", "analytics.max-cache": "Analytics Cache Max Value", From 45a0895c34ef90d572e415faeaa3124066dfd1ff Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Wed, 10 Nov 2021 10:22:12 +0000 Subject: [PATCH 396/412] chore(deps): update dependency eslint-plugin-import to v2.25.3 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 31f91d4c02..22325d77db 100644 --- a/install/package.json +++ b/install/package.json @@ -147,7 +147,7 @@ "coveralls": "3.1.1", "eslint": "7.32.0", "eslint-config-nodebb": "0.0.3", - "eslint-plugin-import": "2.25.2", + "eslint-plugin-import": "2.25.3", "grunt": "1.4.1", "grunt-contrib-watch": "1.1.0", "husky": "7.0.4", From dad31c8ea281ce200d67fe1d19a0411ff51ae5e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 10 Nov 2021 15:32:36 -0500 Subject: [PATCH 397/412] chore: update badges, remove david doesnt work --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 3f1527d221..51aae14227 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,7 @@ # ![NodeBB](public/images/logo.svg) -[![Build Status](https://travis-ci.org/NodeBB/NodeBB.svg?branch=master)](https://travis-ci.org/NodeBB/NodeBB) +![Workflow](https://github.com/NodeBB/NodeBB/actions/workflows/test.yaml/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/NodeBB/NodeBB/badge.svg?branch=master)](https://coveralls.io/github/NodeBB/NodeBB?branch=master) -[![Dependency Status](https://david-dm.org/nodebb/nodebb.svg?path=install)](https://david-dm.org/nodebb/nodebb?path=install) [![Code Climate](https://codeclimate.com/github/NodeBB/NodeBB/badges/gpa.svg)](https://codeclimate.com/github/NodeBB/NodeBB) [**NodeBB Forum Software**](https://nodebb.org) is powered by Node.js and supports either Redis, MongoDB, or a PostgreSQL database. It utilizes web sockets for instant interactions and real-time notifications. NodeBB has many modern features out of the box such as social network integration and streaming discussions, while still making sure to be compatible with older browsers. From a0f0dd021b6b275d377aec83956a8fc0a0e7aa52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 10 Nov 2021 15:33:15 -0500 Subject: [PATCH 398/412] chore: make it a link --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 51aae14227..ec072e3a3a 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # ![NodeBB](public/images/logo.svg) -![Workflow](https://github.com/NodeBB/NodeBB/actions/workflows/test.yaml/badge.svg) +[![Workflow](https://github.com/NodeBB/NodeBB/actions/workflows/test.yaml/badge.svg)](https://github.com/NodeBB/NodeBB/actions/workflows/test.yaml) [![Coverage Status](https://coveralls.io/repos/github/NodeBB/NodeBB/badge.svg?branch=master)](https://coveralls.io/github/NodeBB/NodeBB?branch=master) [![Code Climate](https://codeclimate.com/github/NodeBB/NodeBB/badges/gpa.svg)](https://codeclimate.com/github/NodeBB/NodeBB) From 22e74dc0bb9cf296f548ad3b67ba1d297e4a7dc1 Mon Sep 17 00:00:00 2001 From: "Misty (Bot)" Date: Wed, 10 Nov 2021 20:45:24 +0000 Subject: [PATCH 399/412] chore: incrementing version number - v1.18.6 --- install/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install/package.json b/install/package.json index 22325d77db..b0b48b5c8f 100644 --- a/install/package.json +++ b/install/package.json @@ -2,7 +2,7 @@ "name": "nodebb", "license": "GPL-3.0", "description": "NodeBB Forum", - "version": "1.18.5", + "version": "1.18.6", "homepage": "http://www.nodebb.org", "repository": { "type": "git", From 7ff2b7fbb1e296143bc8cdb9c136767507d1ffd7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 16 Dec 2021 09:53:11 -0500 Subject: [PATCH 400/412] chore: up mentions to fix crash https://github.com/julianlam/nodebb-plugin-mentions/issues/156 --- install/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index b0b48b5c8f..03667b6184 100644 --- a/install/package.json +++ b/install/package.json @@ -89,7 +89,7 @@ "nodebb-plugin-emoji": "^3.5.0", "nodebb-plugin-emoji-android": "2.0.5", "nodebb-plugin-markdown": "8.14.4", - "nodebb-plugin-mentions": "3.0.2", + "nodebb-plugin-mentions": "3.0.3", "nodebb-plugin-spam-be-gone": "0.7.11", "nodebb-rewards-essentials": "0.2.0", "nodebb-theme-lavender": "5.3.1", @@ -182,4 +182,4 @@ "url": "https://github.com/barisusakli" } ] -} \ No newline at end of file +} From edae9522b5535dc7e941edba22a2d2e81f58dae8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 16 Dec 2021 09:54:09 -0500 Subject: [PATCH 401/412] feat: add data to filter:categories.search --- src/categories/search.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/categories/search.js b/src/categories/search.js index 5a19b9fab0..a4f079e2fd 100644 --- a/src/categories/search.js +++ b/src/categories/search.js @@ -18,6 +18,7 @@ module.exports = function (Categories) { let cids = await findCids(query, data.hardCap); const result = await plugins.hooks.fire('filter:categories.search', { + data: data, cids: cids, uid: uid, }); From 1f8f2e916892a5ad388b2eac76cfe761a7e4e5c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 16 Dec 2021 13:26:07 -0500 Subject: [PATCH 402/412] feat: pass in all query params to category search filter --- src/socket.io/categories/search.js | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/socket.io/categories/search.js b/src/socket.io/categories/search.js index 4d973a3f45..529ee136f4 100644 --- a/src/socket.io/categories/search.js +++ b/src/socket.io/categories/search.js @@ -50,12 +50,10 @@ module.exports = function (SocketCategories) { }; async function findMatchedCids(uid, data) { - const result = await categories.search({ - uid: uid, - query: data.search, - paginate: false, - }); - + const params = { ...data, uid, paginate: false }; + params.query = data.search; + params.qs = data.query; + const result = await categories.search(params); let matchedCids = result.categories.map(c => c.cid); // no need to filter if all 3 states are used From 1a375000a7eab014aaecb736c62872a874ad318f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 16 Dec 2021 13:46:49 -0500 Subject: [PATCH 403/412] refactor: only pass qs --- src/socket.io/categories/search.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/socket.io/categories/search.js b/src/socket.io/categories/search.js index 529ee136f4..ad04c20edf 100644 --- a/src/socket.io/categories/search.js +++ b/src/socket.io/categories/search.js @@ -50,10 +50,12 @@ module.exports = function (SocketCategories) { }; async function findMatchedCids(uid, data) { - const params = { ...data, uid, paginate: false }; - params.query = data.search; - params.qs = data.query; - const result = await categories.search(params); + const result = await categories.search({ + uid: uid, + query: data.search, + qs: data.query, + paginate: false, + }); let matchedCids = result.categories.map(c => c.cid); // no need to filter if all 3 states are used From b46dcd9243cafc2b087023345c0ceec51bb9d2ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 23 Dec 2021 11:05:37 -0500 Subject: [PATCH 404/412] fix: use component instead of class name --- public/src/client/topic/threadTools.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/src/client/topic/threadTools.js b/public/src/client/topic/threadTools.js index a393b00b1d..e627a51643 100644 --- a/public/src/client/topic/threadTools.js +++ b/public/src/client/topic/threadTools.js @@ -285,7 +285,7 @@ define('forum/topic/threadTools', [ threadEl.find('[component="post"][data-uid="' + app.user.uid + '"].deleted [component="post/tools"]').toggleClass('hidden', isLocked); - $('.topic-header [component="topic/locked"]').toggleClass('hidden', !data.isLocked); + $('[component="topic/labels"] [component="topic/locked"]').toggleClass('hidden', !data.isLocked); $('[component="post/tools"] .dropdown-menu').html(''); ajaxify.data.locked = data.isLocked; @@ -334,7 +334,7 @@ define('forum/topic/threadTools', [ components.get('topic/pin').toggleClass('hidden', data.pinned).parent().attr('hidden', data.pinned ? '' : null); components.get('topic/unpin').toggleClass('hidden', !data.pinned).parent().attr('hidden', !data.pinned ? '' : null); - const icon = $('.topic-header [component="topic/pinned"]'); + const icon = $('[component="topic/labels"] [component="topic/pinned"]'); icon.toggleClass('hidden', !data.pinned); if (data.pinned) { icon.translateAttr('title', ( From 00a6b05f8905c21725bcf16ce8bc5accf882d32f Mon Sep 17 00:00:00 2001 From: Opliko Date: Sun, 9 Jan 2022 01:26:28 +0100 Subject: [PATCH 405/412] Stop colors.js vandalism (#10131) * fix: pin colors to 1.4.0 * fix: exclude colors from renovate updates --- install/package.json | 2 +- renovate.json | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/install/package.json b/install/package.json index 03667b6184..1f8492be1d 100644 --- a/install/package.json +++ b/install/package.json @@ -41,7 +41,7 @@ "chart.js": "^2.9.4", "cli-graph": "^3.2.2", "clipboard": "^2.0.6", - "colors": "^1.4.0", + "colors": "1.4.0", "commander": "^7.1.0", "compare-versions": "3.6.0", "compression": "^1.7.4", diff --git a/renovate.json b/renovate.json index 78aef7647d..e880233256 100644 --- a/renovate.json +++ b/renovate.json @@ -6,7 +6,8 @@ "packageRules": [ { "updateTypes": ["minor", "patch", "pin", "digest"], - "automerge": true + "automerge": true, + "excludePackageNames": ["colors"] } ] } From 7624af5769134524dee6fdb53db8107477ea4687 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 12 Nov 2021 14:58:02 -0500 Subject: [PATCH 406/412] feat: add feature flag to disable verification emails, closes #9996 --- install/data/defaults.json | 1 + .../language/en-GB/admin/settings/email.json | 3 ++- src/user/email.js | 7 +++++++ src/views/admin/settings/email.tpl | 21 ++++++++++++------- 4 files changed, 24 insertions(+), 8 deletions(-) diff --git a/install/data/defaults.json b/install/data/defaults.json index 52b7683954..cd01e7644a 100644 --- a/install/data/defaults.json +++ b/install/data/defaults.json @@ -138,6 +138,7 @@ "disableEmailSubscriptions": 0, "emailConfirmInterval": 10, "removeEmailNotificationImages": 0, + "sendValidationEmail": 1, "includeUnverifiedEmails": 0, "emailPrompt": 1, "inviteExpiration": 7, diff --git a/public/language/en-GB/admin/settings/email.json b/public/language/en-GB/admin/settings/email.json index 65f579d28c..17c60daf69 100644 --- a/public/language/en-GB/admin/settings/email.json +++ b/public/language/en-GB/admin/settings/email.json @@ -38,7 +38,8 @@ "subscriptions.hour-help": "Please enter a number representing the hour to send scheduled email digests (e.g. 0 for midnight, 17 for 5:00pm). Keep in mind that this is the hour according to the server itself, and may not exactly match your system clock.
    The approximate server time is:
    The next daily digest is scheduled to be sent ", "notifications.remove-images": "Remove images from email notifications", "require-email-address": "Require new users to specify an email address", - "require-email-address-warning": "By default, users can opt-out of entering an email address. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", + "require-email-address-warning": "By default, users can opt-out of entering an email address by leaving the field blank. Enabling this option means they have to enter an email address in order to proceed with registration. It does not ensure user will enter a real email address, nor even an address they own.", + "send-validation-email": "Send validation emails when an email is added or changed", "include-unverified-emails": "Send emails to recipients who have not explicitly confirmed their emails", "include-unverified-warning": "By default, users with emails associated with their account have already been verified, but there are situations where this is not the case (e.g. SSO logins, grandfathered users, etc). Enable this setting at your own risk – sending emails to unverified addresses may be a violation of regional anti-spam laws.", "prompt": "Prompt users to enter or confirm their emails", diff --git a/src/user/email.js b/src/user/email.js index d6d2d32b4d..a97aa1f38f 100644 --- a/src/user/email.js +++ b/src/user/email.js @@ -2,6 +2,7 @@ 'use strict'; const nconf = require('nconf'); +const winston = require('winston'); const user = require('./index'); const utils = require('../utils'); @@ -69,6 +70,11 @@ UserEmail.sendValidationEmail = async function (uid, options) { * - force, sends email even if it is too soon to send another */ + if (meta.config.sendValidationEmail !== 1) { + winston.verbose(`[user/email] Validation email for uid ${uid} not sent due to config settings`); + return; + } + options = options || {}; // Fallback behaviour (email passed in as second argument) @@ -110,6 +116,7 @@ UserEmail.sendValidationEmail = async function (uid, options) { await db.expireAt(`confirm:${confirm_code}`, Math.floor((Date.now() / 1000) + (60 * 60 * 24))); const username = await user.getUserField(uid, 'username'); + winston.verbose(`[user/email] Validation email for uid ${uid} sent to ${options.email}`); events.log({ type: 'email-confirmation-sent', uid, diff --git a/src/views/admin/settings/email.tpl b/src/views/admin/settings/email.tpl index 7f90431b96..e5b3fab134 100644 --- a/src/views/admin/settings/email.tpl +++ b/src/views/admin/settings/email.tpl @@ -20,13 +20,6 @@
    -
    - -
    -

    [[admin/settings/email:require-email-address-warning]]

    +
    + +
    +

    [[admin/settings/email:prompt-help]]

    + +
    + +
    From d19a273ce9a016f3c164076ff399841a00b5d07b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Wed, 2 Mar 2022 11:08:16 -0500 Subject: [PATCH 407/412] fix: #10360, only take top level posts --- public/src/client/topic/posts.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/client/topic/posts.js b/public/src/client/topic/posts.js index b84953e915..498604840a 100644 --- a/public/src/client/topic/posts.js +++ b/public/src/client/topic/posts.js @@ -132,7 +132,7 @@ define('forum/topic/posts', [ if (!isPreviousPostAdded && data.posts[0].selfPost) { return ajaxify.go('post/' + data.posts[0].pid); } - const repliesSelector = $('[component="post"]:not([data-index=0]), [component="topic/event"]'); + const repliesSelector = $('[component="topic"]>[component="post"]:not([data-index=0]), [component="topic"]>[component="topic/event"]'); createNewPosts(data, repliesSelector, direction, false, function (html) { if (html) { html.addClass('new'); From 35f0c559c09ebb2f4461905f73633eca9ec0fd78 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 25 Feb 2022 18:42:45 -0500 Subject: [PATCH 408/412] fix: dont overwrite asset_base_url --- src/prestart.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/prestart.js b/src/prestart.js index 8f89336b9a..f2406e5ace 100644 --- a/src/prestart.js +++ b/src/prestart.js @@ -94,6 +94,9 @@ function loadConfig(configFile) { nconf.set('secure', urlObject.protocol === 'https:'); nconf.set('use_port', !!urlObject.port); nconf.set('relative_path', relativePath); + if (!nconf.get('asset_base_url')) { + nconf.set('asset_base_url', `${relativePath}/assets`); + } nconf.set('port', nconf.get('PORT') || nconf.get('port') || urlObject.port || (nconf.get('PORT_ENV_VAR') ? nconf.get(nconf.get('PORT_ENV_VAR')) : false) || 4567); // cookies don't provide isolation by port: http://stackoverflow.com/a/16328399/122353 From 37ba8a2c8ec078d00b450c65265c69906104cb3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 15 Feb 2022 19:22:34 -0500 Subject: [PATCH 409/412] fix: use asset_base_url --- public/src/ajaxify.js | 2 +- public/src/modules/translator.js | 2 +- src/controllers/api.js | 4 +++- test/mocks/databasemock.js | 1 + 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/public/src/ajaxify.js b/public/src/ajaxify.js index d42a0b89d1..a3cd09757b 100644 --- a/public/src/ajaxify.js +++ b/public/src/ajaxify.js @@ -424,7 +424,7 @@ ajaxify = window.ajaxify || {}; }; ajaxify.loadTemplate = function (template, callback) { - require([config.assetBaseUrl + '/templates/' + template + '.js'], callback, function (err) { + require([config.asset_base_url + '/templates/' + template + '.js'], callback, function (err) { console.error('Unable to load template: ' + template); throw err; }); diff --git a/public/src/modules/translator.js b/public/src/modules/translator.js index 00572536d5..eb40cf658f 100644 --- a/public/src/modules/translator.js +++ b/public/src/modules/translator.js @@ -3,7 +3,7 @@ (function (factory) { function loadClient(language, namespace) { return new Promise(function (resolve, reject) { - jQuery.getJSON([config.assetBaseUrl, 'language', language, namespace].join('/') + '.json?' + config['cache-buster'], function (data) { + jQuery.getJSON([config.asset_base_url, 'language', language, namespace].join('/') + '.json?' + config['cache-buster'], function (data) { const payload = { language: language, namespace: namespace, diff --git a/src/controllers/api.js b/src/controllers/api.js index 984ea98e42..3032fc80ff 100644 --- a/src/controllers/api.js +++ b/src/controllers/api.js @@ -14,6 +14,7 @@ const apiController = module.exports; const relative_path = nconf.get('relative_path'); const upload_url = nconf.get('upload_url'); +const asset_base_url = nconf.get('asset_base_url'); const socketioTransports = nconf.get('socket.io:transports') || ['polling', 'websocket']; const socketioOrigins = nconf.get('socket.io:origins'); const websocketAddress = nconf.get('socket.io:address') || ''; @@ -22,7 +23,8 @@ apiController.loadConfig = async function (req) { const config = { relative_path, upload_url, - assetBaseUrl: `${relative_path}/assets`, + asset_base_url, + assetBaseUrl: asset_base_url, // deprecate in 1.20.x siteTitle: validator.escape(String(meta.config.title || meta.config.browserTitle || 'NodeBB')), browserTitle: validator.escape(String(meta.config.browserTitle || meta.config.title || 'NodeBB')), titleLayout: (meta.config.titleLayout || '{pageTitle} | {browserTitle}').replace(/{/g, '{').replace(/}/g, '}'), diff --git a/test/mocks/databasemock.js b/test/mocks/databasemock.js index 911398b708..414cb7cfdd 100644 --- a/test/mocks/databasemock.js +++ b/test/mocks/databasemock.js @@ -38,6 +38,7 @@ nconf.defaults({ const urlObject = url.parse(nconf.get('url')); const relativePath = urlObject.pathname !== '/' ? urlObject.pathname : ''; nconf.set('relative_path', relativePath); +nconf.set('asset_base_url', `${relativePath}/assets`); nconf.set('upload_path', path.join(nconf.get('base_dir'), nconf.get('upload_path'))); nconf.set('upload_url', '/assets/uploads'); nconf.set('url_parsed', urlObject); From 32b38643f83338d329fe03dac16e88f2abfedffb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Mon, 4 Apr 2022 17:34:52 -0400 Subject: [PATCH 410/412] feat: add response:helpers.notAllowed --- src/controllers/helpers.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/controllers/helpers.js b/src/controllers/helpers.js index 6b91bba943..e53edae33a 100644 --- a/src/controllers/helpers.js +++ b/src/controllers/helpers.js @@ -123,6 +123,11 @@ helpers.buildTerms = function (url, term, query) { helpers.notAllowed = async function (req, res, error) { ({ error } = await plugins.hooks.fire('filter:helpers.notAllowed', { req, res, error })); + await plugins.hooks.fire('response:helpers.notAllowed', { req, res, error }); + if (res.headersSent) { + return; + } + if (req.loggedIn || req.uid === -1) { if (res.locals.isAPI) { if (req.originalUrl.startsWith(`${relative_path}/api/v3`)) { From 804790017001c51af4d0e3ece74f2ad6b47e2eab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Thu, 21 Apr 2022 12:23:37 -0400 Subject: [PATCH 411/412] refactor: skip content length check if submitting from post-queue --- src/topics/create.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/topics/create.js b/src/topics/create.js index 1308827789..d62eb9800c 100644 --- a/src/topics/create.js +++ b/src/topics/create.js @@ -88,7 +88,9 @@ module.exports = function (Topics) { Topics.checkTitle(data.title); await Topics.validateTags(data.tags, data.cid, uid); data.tags = await Topics.filterTags(data.tags, data.cid); - Topics.checkContent(data.content); + if (!data.fromQueue) { + Topics.checkContent(data.content); + } const [categoryExists, canCreate, canTag] = await Promise.all([ categories.exists(data.cid), @@ -165,13 +167,13 @@ module.exports = function (Topics) { data.cid = topicData.cid; await guestHandleValid(data); - if (!data.fromQueue) { - await user.isReadyToPost(uid, data.cid); - } if (data.content) { data.content = utils.rtrim(data.content); } - Topics.checkContent(data.content); + if (!data.fromQueue) { + await user.isReadyToPost(uid, data.cid); + Topics.checkContent(data.content); + } // For replies to scheduled topics, don't have a timestamp older than topic's itself if (topicData.scheduled) { From bba9e7c0f735ccb15ce365d8dfa8b8becd0f4158 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Fri, 22 Apr 2022 12:13:43 -0400 Subject: [PATCH 412/412] refactor: show invalid uri --- src/middleware/helpers.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/middleware/helpers.js b/src/middleware/helpers.js index bbf766895f..5c85989fc0 100644 --- a/src/middleware/helpers.js +++ b/src/middleware/helpers.js @@ -32,6 +32,7 @@ helpers.buildBodyClass = function (req, res, templateData = {}) { try { p = slugify(decodeURIComponent(p)); } catch (err) { + winston.error(`Error decoding URI: ${p}`); winston.error(err.stack); p = ''; }