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

Suggestion: make features filterable by HTML/CSS/JS/etc. #21

Open
SachaG opened this issue Sep 10, 2024 · 4 comments
Open

Suggestion: make features filterable by HTML/CSS/JS/etc. #21

SachaG opened this issue Sep 10, 2024 · 4 comments

Comments

@SachaG
Copy link

SachaG commented Sep 10, 2024

I was browsing https://web-platform-dx.github.io/web-features-explorer/recent/, and it would be quite useful to be able to only show CSS features, or maybe just HTML+JS.

@captainbrosset
Copy link
Contributor

I agree with this. My hope is that we make web-features groups better, and use them to filter the various pages on the explorer.
You can see the groups we currently have on this in-progress page: https://web-platform-dx.github.io/web-features-explorer/groups/

As you can see, not all features are grouped yet. More importantly, we don't really know how we want to group yet. We discussed this on 9/5 (notes). We know they're useful to us right now, and might also become very useful to others (State Of, MDN) in the future. That said, there are many possible ways to group, and only consumers will really know how they want to group.
I think there was some agreement that web-features should still define a default grouping, even if other consumers decide to group differently over time.

That said, let's assume for a minute that all features are grouped, and all our groups are amazing. How would we want to filter the /recent/ (and other) page based on them? I'm imagining a sidebar that shows a treeview representation of the group hierarchy. Clicking on any of the nodes in the treeview would filter features that are in this group.

@SachaG thoughts?

@SachaG
Copy link
Author

SachaG commented Sep 10, 2024

Oh right, I forgot about groups. For my purposes I think I would simply need to be able to filter by JS/CSS/HTML, at least for now. Although more complex filtering would also be cool. Can a feature belong to more than one group by the way?

@captainbrosset
Copy link
Contributor

Yes, features can belong to multiple groups at once.
For your particular case, I wonder if we could also leverage BCD keys to add a filter on the site. For example, the overlay CSS property is referenced in BCD as css.properties.overlay. By extracting the first part of this key, we could tag the features in the explorer, and let you filter by tag.

@captainbrosset
Copy link
Contributor

I know this isn't a filter yet, but just to show progress, I added the first part of BCD key paths and groups to the explorer. Here's what it looks like for now:
image

I'm imagining that clicking on these tags/groups would filter the page to only show the features that belong to the same tag or group.

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

No branches or pull requests

2 participants