feat: add releases widget (#2497)
Co-authored-by: Andre Silva <asilva01@acuitysso.com> Co-authored-by: Meier Lukas <meierschlumpf@gmail.com> Co-authored-by: Manuel <30572287+manuel-rw@users.noreply.github.com>
This commit is contained in:
@@ -7,6 +7,7 @@ import type { ZodType } from "zod";
|
||||
import type { IntegrationKind } from "@homarr/definitions";
|
||||
|
||||
import type { inferSelectOptionValue, SelectOption } from "./_inputs/widget-select-input";
|
||||
import type { ReleasesRepository } from "./releases/releases-repository";
|
||||
|
||||
interface CommonInput<TType> {
|
||||
defaultValue?: TType;
|
||||
@@ -119,6 +120,13 @@ const optionsFactory = {
|
||||
values: [] as string[],
|
||||
validate: input?.validate,
|
||||
}),
|
||||
multiReleasesRepositories: (input?: CommonInput<ReleasesRepository[]> & { validate?: ZodType }) => ({
|
||||
type: "multiReleasesRepositories" as const,
|
||||
defaultValue: input?.defaultValue ?? [],
|
||||
withDescription: input?.withDescription ?? false,
|
||||
values: [] as ReleasesRepository[],
|
||||
validate: input?.validate,
|
||||
}),
|
||||
app: () => ({
|
||||
type: "app" as const,
|
||||
defaultValue: "",
|
||||
|
||||
Reference in New Issue
Block a user