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

fix: Use media query to resize for mobile in SearchFilters #259

Merged
merged 1 commit into from
Jun 2, 2022

Conversation

iloveagent57
Copy link
Contributor

@iloveagent57 iloveagent57 commented Jun 2, 2022

ENT-5800. Also installs react-responsive as a peer dependency.

Something about useWindowSize() from paragon isn't working quite right with the edx.org theme, so our original solution for https://2u-internal.atlassian.net/browse/ENT-5800 isn't working. From Adam:

I think the issue is that useWindowSize is including the extra width of the overflow facets in the total width. for example, at a window width of 1190px but useWindowSize says it's at 1249px, which is still above the breakpoint.

Note that there's still a little overrun from 1200px < screen width < ~1350px, but it's far better than before and I don't want to squish into the mobile view for reasonably-sized desktop browser windows by switching to the XL breakpoint.

media-query

Merge checklist:

  • Evaluate how your changes will impact existing consumers (e.g., frontend-app-learner-portal-enterprise, frontend-app-admin-portal, and frontend-app-enterprise-public-catalog). Will consumers safely be able to upgrade to this change without any breaking changes?
  • Ensure your commit message follows the semantic-release conventional commit message format. If your changes include a breaking change, ensure your commit message is explicitly marked as a BREAKING CHANGE so the NPM package is released as such.
  • Once CI is passing, verify the package versions that Lerna will increment to in the Github Action CI workflow logs.
    • Note: This may be found in the "Preview Updated Versions (dry run)" step in the Github Action CI workflow logs.

Post merge:

  • Verify Lerna created a release commit (e.g., chore(release): publish) that incremented versions in relevant package.json and CHANGELOG files, and created Git tags for those versions.
  • Run the Publish from package.json Github Action workflow to publish these new package versions to NPM.
    • This may be triggered by clicking the "Run workflow" option for the master branch.
  • Verify the new package versions were published to NPM (i.e., npm view <package_name> versions --json).
    • Note: There may be a slight delay between when the workflow finished and when NPM reports the package version as being published. If it doesn't appear right away in the above command, try again in a few minutes.

@iloveagent57 iloveagent57 force-pushed the aed/search-filters-media-query branch 2 times, most recently from d81285f to 3357466 Compare June 2, 2022 17:55
packages/catalog-search/package.json Outdated Show resolved Hide resolved
packages/catalog-search/src/SearchFilters.jsx Outdated Show resolved Hide resolved
@iloveagent57 iloveagent57 force-pushed the aed/search-filters-media-query branch 8 times, most recently from 8c91eb1 to 0743c49 Compare June 2, 2022 20:07
ENT-5800.  Upgrades paragon dev dependency to 19.
@iloveagent57 iloveagent57 force-pushed the aed/search-filters-media-query branch from 0743c49 to 0153fca Compare June 2, 2022 20:09
@codecov
Copy link

codecov bot commented Jun 2, 2022

Codecov Report

Merging #259 (0153fca) into master (85e3ce1) will decrease coverage by 0.40%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #259      +/-   ##
==========================================
- Coverage   76.39%   75.99%   -0.41%     
==========================================
  Files          33       33              
  Lines         610      604       -6     
  Branches      155      152       -3     
==========================================
- Hits          466      459       -7     
- Misses        131      132       +1     
  Partials       13       13              
Impacted Files Coverage Δ
packages/catalog-search/src/SearchFilters.jsx 73.68% <ø> (-6.32%) ⬇️
packages/catalog-search/src/CurrentRefinements.jsx 78.94% <0.00%> (-2.64%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 85e3ce1...0153fca. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants