-
Notifications
You must be signed in to change notification settings - Fork 3k
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
The type
and status
portion of the router does not use the correct darker text color
#56559
Comments
Triggered auto assignment to @OfstadC ( |
🚨 Edited by proposal-police: This proposal was edited at 2025-02-08 03:25:54 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.The type and status portion of the router does not use the correct darker text color What is the root cause of that problem?In
And the styling is applied via the useMarkdownStyle hook. useMarkdownStyle uses syntax color, and in light mode, the color is set to productLight800, which appears lighter than expected.App/src/hooks/useMarkdownStyle.ts Lines 30 to 32 in b0b7709
What changes do you think we should make in order to solve the problem?We can update the syntax color in light mode to a darker text color, such as App/src/styles/theme/themes/light.ts Line 25 in b0b7709
A safer solution is to introduce a new prop styles, to override markdownStyle. App/src/hooks/useMarkdownStyle.ts Lines 29 to 32 in b0b7709
function useMarkdownStyle(message: string | null = null, excludeStyles: Array<keyof MarkdownStyle> = defaultEmptyArray, styles)
....
syntax: {
color: theme.syntax,
...styles?.syntax,
},
// Alternatively, we can override it like this:
if (styles) {
Object.keys(styles).forEach((key) => {
if (styles[key]) {
// Merge nested objects
styling[key] = { ...styling[key], ...styles[key] };
}
});
} Then, in SearchAutocompleteInput, we can override the markdown style like this: markdownStyle={{syntax:{color:theme.darkerColor}}} //The color based on design
const markdownStyle = useMarkdownStyle(undefined, excludedMarkdownStyles,inputProps?.markdownStyle); What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?N/A, UI bug What alternative solutions did you explore? (Optional)N/A |
Related to #56560 |
Hi, I am Adam from SWM and I would like to work on this issue. It is a regression from my PR #56243 cc @luacmartins for visibility |
Thanks @289Adam289 ! |
@289Adam289 before you start working on this. Let's first agree on the expected behavior since this is the expected behavior described in the design doc. |
The only thing I think we need to change is just change the color from textSupporting to our regular text color. Any normal text that's in the router should just use our normal text color. |
We've added quite a bit of code just to change syntax color to textSupporting. Could you confirm if the decision on supportingText color is intended to be permanent. If so I think there's no point in keeping this logic in the codebase and I will go ahead and remove it. Other wise just changing the color should be enough. |
I feel quite strongly that using the gray text was a mistake, so I would love it if we could revert this back to our normal text color. I think we're still waiting for @JmillsExpensify to chime in though. |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 9.0.95-1
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?:
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @shawnborton
Slack conversation (hyperlinked to channel name): Expense
Action Performed:
Expected Result:
The
type
andstatus
portion of the router use the correct darker text colorActual Result:
The
type
andstatus
portion of the router does not use the correct darker text colorWorkaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
View all open jobs on GitHub
Issue Owner
Current Issue Owner: @289Adam289The text was updated successfully, but these errors were encountered: