Commit c19431eb authored by unipadmini's avatar unipadmini Committed by GitHub

fix: Issue where decimal appears as 0 on listings page. (#5354)

* Fix issue where decimal appears as 0.

* Checking explicit value.
Co-authored-by: default avatarPadmini Pyapali <padminipyapali@Padminis-MacBook-Pro.local>
parent 634e3852
......@@ -183,6 +183,9 @@ const PriceTextInput = ({
}}
ref={inputRef}
onChange={(v: FormEvent<HTMLInputElement>) => {
if (!listPrice && v.currentTarget.value === '0.') {
return
}
const val = parseFloat(v.currentTarget.value)
setListPrice(isNaN(val) ? undefined : val)
}}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment