mirror of
https://github.com/RayLabsHQ/gitea-mirror.git
synced 2025-12-17 03:43:46 +03:00
ui: align cleanup retention controls
This commit is contained in:
@@ -279,34 +279,34 @@ export function AutomationSettings({
|
|||||||
</Tooltip>
|
</Tooltip>
|
||||||
</TooltipProvider>
|
</TooltipProvider>
|
||||||
</Label>
|
</Label>
|
||||||
<Select
|
<div className="flex items-center gap-3 mt-1.5">
|
||||||
value={cleanupConfig.retentionDays.toString()}
|
<Select
|
||||||
onValueChange={(value) =>
|
value={cleanupConfig.retentionDays.toString()}
|
||||||
onCleanupChange({
|
onValueChange={(value) =>
|
||||||
...cleanupConfig,
|
onCleanupChange({
|
||||||
retentionDays: parseInt(value, 10),
|
...cleanupConfig,
|
||||||
})
|
retentionDays: parseInt(value, 10),
|
||||||
}
|
})
|
||||||
>
|
}
|
||||||
<SelectTrigger id="retention-period" className="mt-1.5">
|
>
|
||||||
<SelectValue />
|
<SelectTrigger id="retention-period" className="w-40">
|
||||||
</SelectTrigger>
|
<SelectValue />
|
||||||
<SelectContent>
|
</SelectTrigger>
|
||||||
{retentionPeriods.map((option) => (
|
<SelectContent>
|
||||||
<SelectItem
|
{retentionPeriods.map((option) => (
|
||||||
key={option.value}
|
<SelectItem
|
||||||
value={option.value.toString()}
|
key={option.value}
|
||||||
>
|
value={option.value.toString()}
|
||||||
{option.label}
|
>
|
||||||
</SelectItem>
|
{option.label}
|
||||||
))}
|
</SelectItem>
|
||||||
</SelectContent>
|
))}
|
||||||
</Select>
|
</SelectContent>
|
||||||
{cleanupConfig.enabled && (
|
</Select>
|
||||||
<p className="text-xs text-muted-foreground mt-1">
|
<p className="text-xs text-muted-foreground">
|
||||||
Cleanup runs {getCleanupFrequencyText(cleanupConfig.retentionDays)}
|
Cleanup runs {getCleanupFrequencyText(cleanupConfig.retentionDays)}
|
||||||
</p>
|
</p>
|
||||||
)}
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user