Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
This pull request has been ignored for the connected project Preview Branches by Supabase. |
4b48af0 to
0fcc1e1
Compare
331e048 to
57222f4
Compare
app/features/accounts/account.ts
Outdated
| return new Money({ amount: 0, currency: account.currency }); | ||
| }; | ||
|
|
||
| export const isStarAccount = (account: Account) => |
There was a problem hiding this comment.
I think we should use more descriptive name. If you need to explain what star account is it's a signal name is not good. Maybe internal accounts is better? Loyalty accounts maybe sounds the best
There was a problem hiding this comment.
what happens with this and our other "offline account" pr? if you need mint info to classify account as star, when it is offline, would it get classifed as regular account?
app/features/settings/settings.tsx
Outdated
| <SettingsNavButton to="/settings/accounts"> | ||
| <AccountTypeIcon type={defaultAccount.type} /> | ||
| <AccountTypeIcon | ||
| type={isStarAccount(defaultAccount) ? 'star' : defaultAccount.type} |
There was a problem hiding this comment.
rewards only accounts can be default?
| return ( | ||
| <div className="flex w-full items-center gap-4 px-3 py-4"> | ||
| <AccountTypeIcon type={account.type} /> | ||
| <AccountTypeIcon type={isStarAccount(account) ? 'star' : account.type} /> |
There was a problem hiding this comment.
maybe AccountTypeIcon can renamed to AccountIcon and we can have this logic inside?
| currency?: Currency; | ||
| type?: T; | ||
| excludeStarAccounts?: boolean; | ||
| starAccountsOnly?: boolean; |
There was a problem hiding this comment.
I think having filter?: 'star' | 'non-star' or internalAccount?: boolean or something liek that makes better api. with this api caller can specify excludeStarAccounts: true and starAccountsOnly: true which doesn't make sense
a490162 to
40972cc
Compare
57222f4 to
f1d1093
Compare
|
this is outdated, I redid this in #758. Closing now |
depends on #658
This introduces basic handling for star accounts. A star account is a cashu account with a mint that only allows internal melts.
star.