Skip to content
This repository has been archived by the owner on Oct 4, 2023. It is now read-only.

[C-2536] Fix track name cutoff #4019

Merged
merged 3 commits into from
Sep 6, 2023
Merged

[C-2536] Fix track name cutoff #4019

merged 3 commits into from
Sep 6, 2023

Conversation

dylanjeffers
Copy link
Contributor

Description

Fixes issue where track names were cutoff weirdly in mobile. This actually has to do with \n in the track name. Regular html converts that into a space, whereas react-native treats it as a line break. The fix for us was to update the Text component to convert \n into spaces

How Has This Been Tested?

All areas where the track name could appear were tested: search results, track page, track tile

@dylanjeffers dylanjeffers requested review from a team and amendelsohn and removed request for a team September 5, 2023 20:36
Copy link
Contributor

@amendelsohn amendelsohn left a comment

Choose a reason for hiding this comment

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

Nice! Interesting bug

return <RNText style={[styles.root, customStyles, style]} {...other} />
const children =
typeof childrenProp === 'string'
? childrenProp.replace('\n', ' ')
Copy link
Contributor

Choose a reason for hiding this comment

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

Neat! How should we be doing line breaks in our own messages? Do you always do two separate messages spaced using flexbox or is there another way?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

its a good question, actually we should probably have a prop here to disable this, since i see some areas of the mobile code where we do explicit line breaks. Ill fix those entries. Do you have an idea on if it should be default on vs off?

Copy link
Contributor

Choose a reason for hiding this comment

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

I think default on is good to prevent the bug reoccurring. As long as it's not too much work to find the existing newline usages, I would go with that.

Copy link
Contributor

Choose a reason for hiding this comment

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

Better to require desired newline cases to be explicit about it so we never do it by accident.

@dylanjeffers dylanjeffers merged commit 16c805e into main Sep 6, 2023
2 checks passed
@dylanjeffers dylanjeffers deleted the dj-c-2536-track-cutoff branch September 6, 2023 21:28
audius-infra pushed a commit that referenced this pull request Sep 9, 2023
[0ca58e7] [C-2994] Improve mobile image selection (#4041) Dylan Jeffers
[5691cc6] [C-3060] Fix mobile outbound link experience (#4055) Dylan Jeffers
[a72a9e1] [PAY-1833] Increase trending playlists fetch limit (#4066) Saliou Diallo
[37bfd6d] Fixes solana-dapp-store ci with new node (#4060) Dylan Jeffers
[093e863] [C-2548] Fix favorites table saved date filter (#4034) Dylan Jeffers
[e810410] [C-3052] Fix playlist page theme (#4050) Dylan Jeffers
[d152724] Revert library stuff for now (#4064) nicoback2
[0abfa97] Fix bad merge breaking main (#4063) nicoback2
[3343e29] Library Feature Branch (#4061) nicoback2
[92edb79] [PAY-1773] Add sorting by buyer name to sales table (#4059) Randy Schott
[12519c1] [C-3056] Fix remix callout text overflow (#4049) Dylan Jeffers
[0b0385b] Fix sdk:update command after node migration (#4058) Randy Schott
[02d89fe] [C-3049] Fix upload type error where upload type is undefined (#4046) Kyle Shanks
[d548f80] [PAY-1794] Check correct balance in withdrawal flow (#4056) Raymond Jacobson
[6827827] Update dapp-store build artifacts audius-infra
[4f6af2c] [PAY-1794] Math.min(withdrawalAmount, latestBalance) after using USDC to pay tx fee (#4054) Raymond Jacobson
[e682483] Fix balance formatting on USDC card (#4053) Reed
[3735666] [PAY-1814] Store USDC balances in wallet slice (#4052) Raymond Jacobson
[8f20bdb] Fix mobile deleted track tile (#4051) Saliou Diallo
[27089bd] [PAY-1753] Implements Withdrawals Page (#4043) Randy Schott
[17284b7] Auto favorite tracks on purchase PAY-1772 (#4048) nicoback2
[91c49fa] Wire up withdraw USDC saga to modal state (#4045) Reed
[72d8eaa] [C-3024] Fix solana dapp store ci (#4044) Dylan Jeffers
[fb22ace] [PAY-1763][PAY-1810] Wire up links to Purchases/Sales pages (#4042) Randy Schott
[c2b7bae] [PAY-1811] Fix default/empty profile picture in now playing bar/dashboard (#4040) Raymond Jacobson
[52f0375] [PAY-1725] Display proper amount in track sold notification (#4039) Saliou Diallo
[c56596b] [C-3044] Add preview functionality to new upload flow (#4038) Kyle Shanks
[25eb54d] [PAY-1792] Add formik, zod, and proper inputs to USDC withdrawal modal (#4037) Raymond Jacobson
[06b4b42] Symlink react-native for android release (#4023) Sebastian Klingler
[33c5385] Fix Jupiter caching bad route info (#4036) Reed
[60b99b5] [PAY-1510] Add pills and clean up artist dashboard (#4029) Raymond Jacobson
[6447d2c] [C-2841] Use limit + offset for feed (#4032) Dylan Jeffers
[5e8ce0d] [C-2924] Fix ArtistRecommendation description alignment (#4033) Dylan Jeffers
[07bcc8b] [C-2862] Fix clipped repost message text (#4025) Dylan Jeffers
[bed2631] [C-3038] Remove playlist updates feature flags (#4017) Dylan Jeffers
[ae63e6c] [C-2792] Surface play count for hidden tracks (#4022) Dylan Jeffers
[f462539] [PAY-1793] Use existing SOL to fund dest ATA (#4031) Reed
[16c805e] [C-2536] Fix track name cutoff (#4019) Dylan Jeffers
[92e8d52] Add guard to prevent attempted read of undefined queue items (#4030) Randy Schott
[16b3d73] [C-2976] Fix upload form validation timing and display (#4026) Andrew Mendelsohn
[a0e4c56] v1.5.40 (#4024) Sebastian Klingler
[600cf52] [C-2645] Fix icon-info size (#4021) Dylan Jeffers
[4469e92] [C-3039] Add icon to profile share button (#4018) Dylan Jeffers
[f07a4f9] Install pip for android release (#4020) Sebastian Klingler
[e3e2926] Fix support email (#4016) Raymond Jacobson
[bd520f0] [C-2950 C-3033] Fix and simplify issues resulting from collection fetching (#4009) Dylan Jeffers
[361d369] Fix release CI (#4013) Sebastian Klingler
@AudiusProject AudiusProject deleted a comment from linear bot Sep 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants