Merge remote-tracking branch 'origin/master' into develop

isekai-main
Julian Lam 2 years ago
commit 1e864a7518

@ -6,16 +6,6 @@
* bring back treding plugins (8aa1596d)
* incrementing version number - v2.5.2 (babcd17e)
* update changelog for v2.5.2 (84b6a7c7)
* incrementing version number - v2.5.1 (ce3aa950)
* incrementing version number - v2.5.0 (01d276cb)
* incrementing version number - v2.4.5 (dd3e1a28)
* incrementing version number - v2.4.4 (d5525c87)
* incrementing version number - v2.4.3 (9c647c6c)
* incrementing version number - v2.4.2 (3aa7b855)
* incrementing version number - v2.4.1 (60cbd148)
* incrementing version number - v2.4.0 (4834cde3)
* incrementing version number - v2.3.1 (d2425942)
* incrementing version number - v2.3.0 (046ea120)
##### New Features

@ -212,11 +212,17 @@ define('admin/manage/categories', [
const oldParentCid = parseInt(e.from.getAttribute('data-cid'), 10);
const newParentCid = parseInt(e.to.getAttribute('data-cid'), 10);
if (oldParentCid !== newParentCid) {
document.querySelector(`.categories li[data-cid="${newParentCid}"] .toggle`).classList.toggle('hide', false);
const toggle = document.querySelector(`.categories li[data-cid="${newParentCid}"] .toggle`);
if (toggle) {
toggle.classList.toggle('hide', false);
}
const children = document.querySelectorAll(`.categories li[data-cid="${oldParentCid}"] ul[data-cid] li[data-cid]`);
if (!children.length) {
document.querySelector(`.categories li[data-cid="${oldParentCid}"] .toggle`).classList.toggle('hide', true);
const toggle = document.querySelector(`.categories li[data-cid="${oldParentCid}"] .toggle`);
if (toggle) {
toggle.classList.toggle('hide', true);
}
}
e.item.dataset.parentCid = newParentCid;

@ -26,7 +26,7 @@ define('forum/flags/detail', [
return memo;
}, {});
api.put(`/flags/${ajaxify.data.flagId}`, data).then((history) => {
api.put(`/flags/${ajaxify.data.flagId}`, data).then(({ history }) => {
alerts.success('[[flags:updated]]');
Detail.reloadHistory(history);
}).catch(alerts.error);

@ -570,7 +570,7 @@ define('navigator', ['forum/pagination', 'components', 'hooks', 'alerts'], funct
await hooks.fire('filter:navigator.scroll', { scrollTo, highlight, duration, newIndex });
const postHeight = scrollTo.outerHeight(true);
const navbarHeight = components.get('navbar').outerHeight(true);
const navbarHeight = components.get('navbar').outerHeight(true) || 0;
const topicHeaderHeight = $('.topic-header').outerHeight(true) || 0;
const viewportHeight = $(window).height();

@ -41,6 +41,7 @@ try {
checkVersion('commander');
checkVersion('chalk');
checkVersion('lodash');
checkVersion('lru-cache');
} catch (e) {
if (['ENOENT', 'DEP_WRONG_VERSION', 'MODULE_NOT_FOUND'].includes(e.code)) {
console.warn('Dependencies outdated or not yet installed.');

Loading…
Cancel
Save