mirror of
https://github.com/BrenBroZAYT/gameyfin.git
synced 2026-06-17 00:30:04 +00:00
Implement "secret" toggle for plugin config fields
This commit is contained in:
@@ -70,8 +70,9 @@ export default function PluginDetailsModal({plugin, isOpen, onOpenChange, update
|
||||
|
||||
<h4 className="text-l font-bold mt-6">Configuration</h4>
|
||||
{(pluginConfigMeta && pluginConfigMeta.length > 0) ?
|
||||
pluginConfigMeta.map((entry: any) => (
|
||||
<Input key={entry.key} name={entry.key} label={entry.name} type="text"/>
|
||||
pluginConfigMeta.map((entry: PluginConfigElement) => (
|
||||
<Input key={entry.key} name={entry.key} label={entry.name}
|
||||
type={entry.secret ? "password" : "text"}/>
|
||||
)) : "This plugin has no configuration options."
|
||||
}
|
||||
</ModalBody>
|
||||
|
||||
@@ -68,12 +68,12 @@ export function PluginManagementCard({plugin, updatePlugin}: {
|
||||
<div className="absolute right-0 top-0 flex flex-row">
|
||||
<Tooltip content={`${isDisabled(plugin.state) ? "Enable" : "Disable"} plugin`} placement="bottom"
|
||||
color="foreground">
|
||||
<Button isIconOnly variant="ghost" onPress={() => togglePluginEnabled()}>
|
||||
<Button isIconOnly variant="light" onPress={() => togglePluginEnabled()}>
|
||||
<Power/>
|
||||
</Button>
|
||||
</Tooltip>
|
||||
<Tooltip content="Configuration" placement="bottom" color="foreground">
|
||||
<Button isIconOnly variant="ghost" onPress={pluginDetailsModal.onOpen}>
|
||||
<Button isIconOnly variant="light" onPress={pluginDetailsModal.onOpen}>
|
||||
<SlidersHorizontal/>
|
||||
</Button>
|
||||
</Tooltip>
|
||||
|
||||
Reference in New Issue
Block a user