Skip to content

Commit

Permalink
tooltip and placeholder for api key field
Browse files Browse the repository at this point in the history
  • Loading branch information
berekuk committed Nov 21, 2024
1 parent d4ee0b9 commit 51264f0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
1 change: 1 addition & 0 deletions packages/hub/src/app/ai/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ Outputs:
name="anthropicApiKey"
label="Anthropic API Key"
tooltip="Anthropic API key for using Claude."
placeholder="Optional"
size="small"
layout="row"
/>
Expand Down
12 changes: 8 additions & 4 deletions packages/ui/src/forms/common/FormField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,24 @@ export function FormField<
TValues extends FieldValues,
TName extends FieldPath<TValues> = FieldPath<TValues>,
>({
name,
rules,
// FieldLayout props
label,
description,
layout,
standaloneLabel,
layout,
tooltip,
// FormField props
name,
rules,
children,
}: FormFieldProps<TValues, TName>) {
return (
<FieldLayout
label={label}
description={description}
layout={layout}
standaloneLabel={standaloneLabel}
layout={layout}
tooltip={tooltip}
>
<FormInput name={name} rules={rules}>
{children}
Expand Down

0 comments on commit 51264f0

Please sign in to comment.