Fix/multiple generation (#104)

* fixes #100

* Fix test

* fix: fix bad configuration issue
This commit is contained in:
Abhishek 2026-01-03 12:59:18 +05:30 committed by GitHub
parent 90b690efff
commit 56953bbd09
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 758 additions and 460 deletions

View file

@ -10,6 +10,8 @@ import {
HttpMethodSelector,
KeyValueEditor,
type KeyValueItem,
UrlInput,
validateUrl,
} from "@/components/http";
import { Button } from "@/components/ui/button";
import { Input } from "@/components/ui/input";
@ -57,8 +59,9 @@ export const WebhookNode = memo(({ data, selected, id }: WebhookNodeProps) => {
const handleSave = async () => {
// Validate endpoint URL
if (!endpointUrl.trim()) {
setEndpointError('Endpoint URL is required');
const urlValidation = validateUrl(endpointUrl);
if (!urlValidation.valid) {
setEndpointError(urlValidation.error || 'Invalid URL');
return;
}
setEndpointError(null);
@ -284,10 +287,11 @@ const WebhookNodeEditForm = ({
<Label className="text-xs text-muted-foreground">
The URL to send the webhook request to.
</Label>
<Input
<UrlInput
value={endpointUrl}
onChange={(e) => setEndpointUrl(e.target.value)}
onChange={setEndpointUrl}
placeholder="https://api.example.com/webhook"
showValidation
/>
</div>
</TabsContent>