Compare commits

...

6 Commits

Author SHA1 Message Date
Tom Moor 682fbeb10a Merge main 2024-06-16 12:42:32 -04:00
Tom Moor 391f72aeb4 Add config on Settings plugin 2024-06-16 10:16:54 -04:00
Tom Moor 1b95838a16 Rebase main 2024-06-16 10:06:05 -04:00
Tom Moor fc8a491133 tsc 2024-06-16 10:04:53 -04:00
Tom Moor b219e42cc8 docs 2024-06-16 10:04:53 -04:00
Tom Moor f4e2c2de77 Update clientside plugin management to work as server 2024-06-16 10:04:53 -04:00
2 changed files with 7 additions and 3 deletions
+5 -3
View File
@@ -188,9 +188,11 @@ const useSettingsConfig = () => {
// Plugins
PluginManager.getHooks(Hook.Settings).forEach((plugin) => {
const insertIndex = items.findIndex(
(i) => i.group === t(plugin.value.group ?? "Integrations")
);
const insertIndex = plugin.value.after
? items.findIndex((i) => i.name === t(plugin.value.after!)) + 1
: items.findIndex(
(i) => i.group === t(plugin.value.group ?? "Integrations")
);
items.splice(insertIndex, 0, {
name: t(plugin.name),
path: integrationSettingsPath(plugin.id),
+2
View File
@@ -20,6 +20,8 @@ type PluginValueMap = {
[Hook.Settings]: {
/** The group in settings sidebar this plugin belongs to. */
group: string;
/** An optional settings item to display this after. */
after?: string;
/** The displayed icon of the plugin. */
icon: React.ElementType;
/** The settings screen somponent, should be lazy loaded. */