aboutsummaryrefslogtreecommitdiffhomepage
path: root/plugins/default_colors
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2020-12-29 11:59:14 +0100
committerArthurHoaro <arthur@hoa.ro>2020-12-29 11:59:14 +0100
commit035a002edc7376a961e5621dc1039b082637fbc6 (patch)
tree7160dbf2ff8f699d4dc818492676aa7cc02043f3 /plugins/default_colors
parentf2e309b67d92ea19e47f1fc6b9a676c19d8cf33d (diff)
downloadShaarli-035a002edc7376a961e5621dc1039b082637fbc6.tar.gz
Shaarli-035a002edc7376a961e5621dc1039b082637fbc6.tar.zst
Shaarli-035a002edc7376a961e5621dc1039b082637fbc6.zip
Fix default_colors plugin: update CSS file on color change
Last update of this plugin remove the save_plugin_parameters hook. Fixes #1657
Diffstat (limited to 'plugins/default_colors')
-rw-r--r--plugins/default_colors/default_colors.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/plugins/default_colors/default_colors.php b/plugins/default_colors/default_colors.php
index 574a0bd4..d3e1fa76 100644
--- a/plugins/default_colors/default_colors.php
+++ b/plugins/default_colors/default_colors.php
@@ -47,6 +47,20 @@ function default_colors_init($conf)
47} 47}
48 48
49/** 49/**
50 * When plugin parameters are saved, we regenerate the custom CSS file with provided settings.
51 *
52 * @param array $data $_POST array
53 *
54 * @return array Updated $_POST array
55 */
56function hook_default_colors_save_plugin_parameters($data)
57{
58 default_colors_generate_css_file($data);
59
60 return $data;
61}
62
63/**
50 * When linklist is displayed, include default_colors CSS file. 64 * When linklist is displayed, include default_colors CSS file.
51 * 65 *
52 * @param array $data - header data. 66 * @param array $data - header data.