History

Seed add form identity from the catalog preset name

Rhys Sullivan committed 4 months ago

Commit c2f60581 parent 70b6b761 file · +2 −1Browse files

Unified · Split

packages/plugins/openapi/src/react/AddOpenApiSource.tsx+2−1
@@ -111,7 +111,8 @@ export default function AddOpenApiSource(props: { · 110 unmodified lines
111 // Agent-visible description: prefilled from the spec's `info.description`111 // Agent-visible description: prefilled from the spec's `info.description`
112 // until the user types (null = untouched, keep deriving from the preview).112 // until the user types (null = untouched, keep deriving from the preview).
113 const [descriptionDraft, setDescriptionDraft] = useState<string | null>(null);113 const [descriptionDraft, setDescriptionDraft] = useState<string | null>(null);
114 const identityFallbackName = preview ? Option.getOrElse(preview.title, () => "") : "";114 const identityFallbackName =
115 initialPreset?.name ?? (preview ? Option.getOrElse(preview.title, () => "") : "");
115 const identity = useIntegrationIdentity({116 const identity = useIntegrationIdentity({
116 fallbackName: identityFallbackName,117 fallbackName: identityFallbackName,
117 fallbackNamespace: props.initialNamespace,118 fallbackNamespace: props.initialNamespace,