Skip to content

Commit

Permalink
added event handling for the input field
Browse files Browse the repository at this point in the history
  • Loading branch information
danikova committed Dec 3, 2023
1 parent 227ef9a commit 8b445cf
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/components/settings-form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,13 @@ export function SettingsForm({
Background picture <span className="opacity-50">(imgur image id)</span>
</Label>
<div className="flex gap-x-4">
<Input autoFocus={false} value={imageId} />
<Input
autoFocus={false}
value={imageId}
onChange={(e) => {
setDirtyData({ imageId: e.target.value });
}}
/>
<PictureUpload
btnText={imageId ? "Replace" : "Upload"}
onChange={(value) => {
Expand Down

0 comments on commit 8b445cf

Please sign in to comment.