mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-23 08:23:12 +09:00
Fix errors detected by linter
I meant to fix these changes before pushing the PR, but forgot about it.
This commit is contained in:
1 parent
7797ee708a
commit
bdd70e53dc
2 files changed
+5
-5
No files matched your search
@@ -12,7 +12,7 @@ export default function PluginViewPage() {
|
|||||||
let plugins = useContext(PluginsContext);
|
let plugins = useContext(PluginsContext);
|
||||||
let pluginName = params.name;
|
let pluginName = params.name;
|
||||||
|
|
||||||
let plugin = plugins.find(plugin => plugin.meta.name === pluginName);
|
let plugin = plugins.find(p => p.meta.name === pluginName);
|
||||||
let pluginTitle = plugin.info ? plugin.info.title : plugin.meta.name;
|
let pluginTitle = plugin.info ? plugin.info.title : plugin.meta.name;
|
||||||
let nav = [{ name: "Plugins", path: "/plugins" }, { name: pluginTitle }];
|
let nav = [{ name: "Plugins", path: "/plugins" }, { name: pluginTitle }];
|
||||||
if (!plugin) {
|
if (!plugin) {
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ export default function PluginsPage() {
|
|||||||
{
|
{
|
||||||
title: "Name",
|
title: "Name",
|
||||||
key: "name",
|
key: "name",
|
||||||
render: plugin => plugin.info ? plugin.info.title : plugin.meta.name,
|
render: plugin => (plugin.info ? plugin.info.title : plugin.meta.name),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "Version",
|
title: "Version",
|
||||||
@@ -30,12 +30,12 @@ export default function PluginsPage() {
|
|||||||
return "Version missmatched";
|
return "Version missmatched";
|
||||||
}
|
}
|
||||||
return plugin.package.version;
|
return plugin.package.version;
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "Enabled",
|
title: "Enabled",
|
||||||
dataIndex: ["meta", "enabled"],
|
dataIndex: ["meta", "enabled"],
|
||||||
render: enabled => enabled ? "Yes" : null,
|
render: enabled => (enabled ? "Yes" : null),
|
||||||
responsive: ["sm"],
|
responsive: ["sm"],
|
||||||
},
|
},
|
||||||
]}
|
]}
|
||||||
@@ -45,7 +45,7 @@ export default function PluginsPage() {
|
|||||||
onRow={plugin => ({
|
onRow={plugin => ({
|
||||||
onClick: event => {
|
onClick: event => {
|
||||||
history.push(`/plugins/${plugin.meta.name}/view`);
|
history.push(`/plugins/${plugin.meta.name}/view`);
|
||||||
}
|
},
|
||||||
})}
|
})}
|
||||||
/>
|
/>
|
||||||
</PageLayout>;
|
</PageLayout>;
|
||||||
|
|||||||
Reference in new issue
Block a user