-
Notifications
You must be signed in to change notification settings - Fork 350
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
✨feat(lld): UI of rare sats table #7756
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 5 Skipped Deployments
|
7f67040
to
3ee6fcc
Compare
3ee6fcc
to
665d987
Compare
...ledger-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/index.tsx
Outdated
Show resolved
Hide resolved
...-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/useRareSatsModel.tsx
Outdated
Show resolved
Hide resolved
18236ed
to
89628ef
Compare
60b2d03
to
dda4017
Compare
...-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/useRareSatsModel.tsx
Outdated
Show resolved
Hide resolved
4372a25
to
775254f
Compare
...-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/TableHeader.tsx
Outdated
Show resolved
Hide resolved
...-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/TableHeader.tsx
Outdated
Show resolved
Hide resolved
775254f
to
366226d
Compare
<TableHeader titleKey={TableHeaderTitleKey.RareSats} /> | ||
<TableHeaderContainer /> | ||
<Flex flexDirection={"column"}> | ||
{rareSats.map((rareSatGroup, index) => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you may should handle the UI case where rareStats is empty or undefined . Show the corresponding UI of it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes I don't have the design for that for the moment I will do it asap
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
at lease return null
...ledger-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/index.tsx
Outdated
Show resolved
Hide resolved
...ledger-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/index.tsx
Outdated
Show resolved
Hide resolved
...ledger-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/index.tsx
Outdated
Show resolved
Hide resolved
...ledger-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/index.tsx
Outdated
Show resolved
Hide resolved
366226d
to
a9d588c
Compare
const firstColumn = ( | ||
<Text variant="bodyLineHeight" fontSize={12} color="neutral.c70"> | ||
{t("ordinals.rareSats.table.type")} | ||
</Text> | ||
); | ||
|
||
const secondColumn = ( | ||
<Text variant="bodyLineHeight" fontSize={12} color="neutral.c70"> | ||
{t("ordinals.rareSats.table.year")} | ||
</Text> | ||
); | ||
|
||
const thirdColumn = ( | ||
<Text variant="bodyLineHeight" fontSize={12} color="neutral.c70"> | ||
{t("ordinals.rareSats.table.utxo")} | ||
</Text> | ||
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not mandatory but you could have created a generic component that takes a string as parameter :)
return processSatRanges(satRanges, satributes); | ||
}; | ||
|
||
const processRareSats = (mockedRareSats: MockedRareSat[]) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const processRareSats = (mockedRareSats: MockedRareSat[]) => { | |
const processRareSats = (rareSats: MockedRareSat[]) => { |
maybe ? because in the near futur it will not be mocked
d1d2d5e
to
aba8ece
Compare
...-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/useRareSatsModel.tsx
Outdated
Show resolved
Hide resolved
...-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/useRareSatsModel.tsx
Outdated
Show resolved
Hide resolved
...-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/useRareSatsModel.tsx
Outdated
Show resolved
Hide resolved
...-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/useRareSatsModel.tsx
Outdated
Show resolved
Hide resolved
<TableHeader titleKey={TableHeaderTitleKey.RareSats} /> | ||
<TableHeaderContainer /> | ||
<Flex flexDirection={"column"}> | ||
{rareSats.map((rareSatGroup, index) => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
at lease return null
...ledger-live-desktop/src/newArch/features/Collectibles/Ordinals/components/RareSats/index.tsx
Outdated
Show resolved
Hide resolved
aba8ece
to
bd17b01
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work ! thank you
5a62dd9
bd17b01
to
5a62dd9
Compare
✅ Checklist
npx changeset
was attached.📝 Description
Note
This implements the UI of rare sats table. It's not the same as the inscription table so it needed few adjustments. For the moment it's only mocked data.
I've tried to simplify the logic to group and extract the data from the json but it's quite complex since we need to order and group the rareSat with multiple conditions that use different object inside the returned json
In the case where a sat key from the api won't match with the key from mappingKeyIcon the concerned sat won't be displayed.
we can compare the table that we have with the data displayed on MagicEden. For the mocked account see this link
the table doesn't match exactly as the figma (for the utxo size when multiple rows) since it would make it quite more complex
if you want to test it you just have to enable the ordinals ff in the settings
Screen.Recording.2024-09-09.at.11.02.33.mov
Screen.Recording.2024-09-09.at.11.55.56.mov
❓ Context
🧐 Checklist for the PR Reviewers