Skip to content

Commit

Permalink
fix(web): fix recharge display & modal open (#1274)
Browse files Browse the repository at this point in the history
* fix(web): hide bonus when no bonus

* fix(web): fix amount display

* fix(web): fix can't open charge modal

* fix(web): fix typo

* fix(web): fix bonus display
  • Loading branch information
newfish-cmyk authored Jun 17, 2023
1 parent 4efd3b5 commit eaad7ea
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions web/src/components/ChargeButton/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -146,19 +146,16 @@ export default function ChargeButton(props: { amount?: number; children: React.R
}
}}
/>
{bonus && (
{bonus && matchBonus(amount * 100) && (
<div>
<span className="ml-3 whitespace-nowrap rounded-full rounded-bl-none bg-purple-200 px-2 py-[1.5px] text-[12px] text-purple-600">
{t("application.bonus")}
</span>
<span className="pl-1 font-semibold">¥{matchBonus(amount * 100) || 0}</span>
<span className="pl-1 font-semibold">¥{matchBonus(amount * 100)}</span>
</div>
)}
</InputGroup>
{/* <span className="flex items-center cursor-pointer text-[#1D8CDC] pb-6">
<InfoOutlineIcon className="mr-2" />
查看优惠规则
</span> */}
<Button
isDisabled={!amount || !isNumber(amount)}
className="!h-9 w-full !rounded-full"
Expand Down

0 comments on commit eaad7ea

Please sign in to comment.