keep board horizontal scroll across refresh: restore scrollLeft after #board-container rebuild; v1.0
This commit is contained in:
10
Plugin.php
10
Plugin.php
@@ -26,6 +26,14 @@ class Plugin extends Base
|
||||
if ((int) $this->configModel->get('organon_tweaks_always_comment_icon', 1) === 1) {
|
||||
$this->template->hook->attach('template:board:task:icons', 'organonTweaks:board/task_comment_icon');
|
||||
}
|
||||
|
||||
// Tweak: keep the board horizontal scroll position across refreshes (Kanboard
|
||||
// rebuilds #board-container on card drop / polling, resetting scrollLeft to 0).
|
||||
if ((int) $this->configModel->get('organon_tweaks_keep_scroll', 1) === 1) {
|
||||
$this->hook->on('template:layout:js', array(
|
||||
'template' => 'plugins/OrganonTweaks/Asset/js/keep-scroll.js',
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
public function getHelpers()
|
||||
@@ -52,7 +60,7 @@ class Plugin extends Base
|
||||
|
||||
public function getPluginVersion()
|
||||
{
|
||||
return '0.3.1';
|
||||
return '1.0.0';
|
||||
}
|
||||
|
||||
public function getPluginHomepage()
|
||||
|
||||
Reference in New Issue
Block a user