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

feat: Adjust library home filter styles #45

Conversation

yusuf-musleh
Copy link

@yusuf-musleh yusuf-musleh commented Jun 26, 2024

Description

This PR adjust the styles for the filters present on the Library Home page to closer match the styles in Figma.

  1. Swapped the order of the filters. Tags first then BlockType
  2. Added the icons inside the filter buttons
  3. Made sure the filters styles are applied in both the search modal and the library home page

Testing Instructions

  1. Run this branch locally
  2. Confirm that the styles match what you see in the following screenshots:
Screenshot 2024-06-26 at 10 09 32 PM Screenshot 2024-06-26 at 10 10 13 PM Screenshot 2024-06-26 at 10 18 40 PM

Private-ref: FAL-3763

const iconMap = {
blockType: FilterList,
tags: Tag,
};
Copy link
Member

Choose a reason for hiding this comment

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

The SearchFilterWidget is a generic component, and it shouldn't need to know about what type of filters may use it. In other words, it shouldn't need iconMap. Instead, I recommend it just accept an icon prop, and then the widgets like <FilterByBlockType> can pass in icon={FilterList}.

Copy link
Author

Choose a reason for hiding this comment

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

Good point, thanks for that! I've updated it

@yusuf-musleh yusuf-musleh force-pushed the yusuf-musleh/library-home-filters-styling branch from 2ff49f7 to b4374e9 Compare June 28, 2024 07:11
@rpenido rpenido merged commit 3cc07ae into rpenido/fal-3764-library-home-filter-by-content-type Jul 3, 2024
2 of 3 checks passed
@bradenmacdonald bradenmacdonald deleted the yusuf-musleh/library-home-filters-styling branch July 23, 2024 01:06
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.

3 participants