-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[$250] [HOLD for payment 2024-03-29] Newly added tag is not arranged in alphabetical order #38261
Comments
Triggered auto assignment to @kevinksullivan ( |
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
|
Triggered auto assignment to @marcaaron ( |
@marcaaron FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors. |
We think that this bug might be related to #wave-control |
It's a deploy blocker so it should really be fixed by whoever broke this. |
Seems related to #37870 cc @luacmartins |
I can take this over! Thanks for the ping! |
ProposalPlease re-state the problem that we are trying to solve in this issue.
What is the root cause of that problem?
What changes do you think we should make in order to solve the problem?
What alternative solutions did you explore? (Optional)
|
I think this does not have to be a blocker |
ProposalPlease re-state the problem that we are trying to solve in this issue.Newly added tag is not arranged in alphabetical order What is the root cause of that problem?Currently we don't sort the tags before mapping App/src/pages/workspace/tags/WorkspaceTagsPage.tsx Lines 65 to 70 in 206d293
We display these tags as the BE sends us, and when we add new tags, we directly show them at the end of the list. What changes do you think we should make in order to solve the problem?Don't rely on the BE, sort them on the frontend as well, update the const tagList = useMemo<PolicyForList[]>(
() =>
policyTagLists
- .map((policyTagList) =>
- Object.values(policyTagList.tags || []).map((value) => ({
+ .flatMap((policyTagList) =>
+ Object.values(policyTagList.tags || []).sort((a, b) => a.name.localeCompare(b.name)).map((value) => ({
value: value.name,
text: value.name,
keyForList: value.name,
isSelected: !!selectedTags[value.name],
rightElement: (
<View style={styles.flexRow}>
<Text style={[styles.textSupporting, styles.alignSelfCenter, styles.pl2, styles.label]}>
{value.enabled ? translate('workspace.common.enabled') : translate('workspace.common.disabled')}
</Text>
<View style={[styles.p1, styles.pl2]}>
<Icon
src={Expensicons.ArrowRight}
fill={theme.icon}
/>
</View>
</View>
),
})),
)
- .flat(),
[policyTagLists, selectedTags, styles.alignSelfCenter, styles.flexRow, styles.label, styles.p1, styles.pl2, styles.textSupporting, theme.icon, translate],
);
Note:This behavior would be consistent with App/src/pages/workspace/categories/WorkspaceCategoriesPage.tsx Lines 73 to 77 in aa46730
|
This is not a blocker since the feature is still WIP. PR to fix it here |
Just pending payment |
Bump for payment @kevinksullivan |
Bump for payment @kevinksullivan |
@luacmartins, @kevinksullivan, @situchan Whoops! This issue is 2 days overdue. Let's get this updated quick! |
Bump @kevinksullivan for payment |
Same as other issue, waiting for @situchan to accept. |
Still waiting on @situchan |
@kevinksullivan sorry I am back from vacay. Can you please send new offer? Old one was expired. |
All good! |
@situchan fresh offer here |
all set |
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: 1.4.52-0
Reproducible in staging?: y
Reproducible in production?: y
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: applause internal team
Slack conversation:
Action Performed:
Precondition:
Expected Result:
The new tag will be arranged in alphabetical order.
Actual Result:
The new tag is not arranged in alphabetical order. It only follows the order after refreshing the page.
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6412861_1710369790458.bandicam_2024-03-14_04-16-06-302.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @kevinksullivanThe text was updated successfully, but these errors were encountered: