Skip to content
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

Nav Unification: Improve 'selected' detection #45973

Merged
merged 1 commit into from
Sep 29, 2020

Conversation

mreishus
Copy link
Contributor

@mreishus mreishus commented Sep 28, 2020

Changes proposed in this Pull Request

  • Change the method that <MySitesSidebarUnifiedItem> uses to detect "selected" items

Example

path = "/posts/example.com?flags=nav-unification"
url = "/posts/example.com"

path === url was not true in this case, but itemLinkMatches(url, path) is.

Testing instructions

Related to #45435

Example:
path = "/posts/testsite5mmr.wordpress.com?flags=nav-unification"
url = "/posts/testsite5mmr.wordpress.com"

path === url was not true in this case, but itemLinkMatches(url, path)
is.
@matticbot
Copy link
Contributor

@mreishus mreishus requested a review from a team September 28, 2020 21:48
@matticbot matticbot added the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Sep 28, 2020
@mreishus mreishus self-assigned this Sep 28, 2020
@matticbot
Copy link
Contributor

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

Async-loaded Components (~14 bytes added 📈 [gzipped])

name                                          parsed_size           gzip_size
async-load-my-sites-sidebar-unified-switcher        +46 B  (+0.0%)      +14 B  (+0.0%)

React components that are loaded lazily, when a certain part of UI is displayed for the first time.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

Copy link
Member

@obenland obenland left a comment

Choose a reason for hiding this comment

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

:shipit:

@obenland obenland removed the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Sep 28, 2020
@obenland
Copy link
Member

@Automattic/lighthouse Is that failing check to be expected in PRs that don't mention you?

@lezama
Copy link
Contributor

lezama commented Sep 29, 2020

looks like a random error in github actions, I just re ran the tests and everything is green now, thank for checking @obenland 🥇

@cpapazoglou cpapazoglou merged commit f552626 into master Sep 29, 2020
@cpapazoglou cpapazoglou deleted the fix/unified-sidebar-selected branch September 29, 2020 06:38
@cpapazoglou cpapazoglou mentioned this pull request Sep 29, 2020
94 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants