Skip to content

Commit

Permalink
fix: decimal input
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelblijleven committed Jun 12, 2023
1 parent b4f56e4 commit ce59f12
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/ratio-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ const UserInput = ({id, label, value, onChange, prefix}: UserInputProps) => (
value={value}
type={"number"}
className={"text-lg"}
inputMode={"decimal"}
onChange={onChange}
/>)}
{!!prefix && (
Expand All @@ -38,6 +39,7 @@ const UserInput = ({id, label, value, onChange, prefix}: UserInputProps) => (
value={value}
type={"number"}
className={"text-lg"}
inputMode={"decimal"}
onChange={onChange}
/>
)}
Expand Down Expand Up @@ -65,7 +67,7 @@ const RatioCard = () => {
if (value === "") {
return setFunc(undefined);
}
setFunc(parseInt(value))
setFunc(value)
}

const onChangeWater = onChange(setWater);
Expand Down

1 comment on commit ce59f12

@vercel
Copy link

@vercel vercel bot commented on ce59f12 Jun 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

beans – ./

beanstats.vercel.app
beans-marcelblijleven.vercel.app
beans-git-main-marcelblijleven.vercel.app

Please sign in to comment.