mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
* add: test btn * fix * fix --------- Co-authored-by: Théo LAGACHE <theo.lagache@soluce-technologies.com>
39 lines
953 B
TypeScript
39 lines
953 B
TypeScript
import { UseFormReturn } from "react-hook-form";
|
|
import {
|
|
FormControl,
|
|
FormField,
|
|
FormItem,
|
|
FormLabel,
|
|
FormMessage,
|
|
} from "@/components/ui/form";
|
|
import { Separator } from "@/components/ui/separator";
|
|
import { PasswordInput } from "@/components/ui/password-input";
|
|
|
|
type NotifierSmtpFormProps = {
|
|
form: UseFormReturn<any, any, any>;
|
|
};
|
|
|
|
export const NotifierSlackForm = ({ form }: NotifierSmtpFormProps) => {
|
|
return (
|
|
<>
|
|
<Separator className="my-1" />
|
|
<FormField
|
|
control={form.control}
|
|
name="config.slackWebhook"
|
|
render={({ field }) => (
|
|
<FormItem>
|
|
<FormLabel>Slack Webhook URL *</FormLabel>
|
|
<FormControl>
|
|
<PasswordInput
|
|
{...field}
|
|
placeholder="e.g. https://hooks.slack.com/services/..."
|
|
/>
|
|
</FormControl>
|
|
<FormMessage />
|
|
</FormItem>
|
|
)}
|
|
/>
|
|
</>
|
|
);
|
|
};
|