-
Notifications
You must be signed in to change notification settings - Fork 197
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
useSensitiveMedia composable #2700
Conversation
Size Change: +168 B (0%) Total Size: 837 kB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for extracting these changes, they are really fun! They work well, but I found a problem with implementation, and one suggestion on possible simplification using Set
.
The biggest blocker is the uiStore
watcher that is called by every component using use-sensitive-media
composable.
…d sensitive uuids on blur toggle
Co-authored-by: Olga Bulat <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works well and has great tests :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, this is a good abstraction over the sensitivity functionality.
Fixes
Related to #2462 by @dhruvkb
Description
This PR creates a new
useSensitiveMedia
composable for working with sensitive media, and updates the blurring logic to use this composable. This composable is fully tested with a unit test, and forms the basis of the "backend" work for the single result sensitivity UI. It includes hide/reveal methods that aren't used by this PR but will be for the VSafetyWall.This PR also adds revealedSensitiveResults, a list of UUIDs of revealed sensitive media, to the UI store.
It was extracted into a standalone PR for ease of reviewing.
Testing Instructions
Check that blurring still works as-expected in the frontend search results, when all relevant
/preferences
toggles are enabled. Check that you like theuseSensitiveMedia
implementation and that test coverage is sufficient.Checklist
Update index.md
).main
) or a parent feature branch.Developer Certificate of Origin
Developer Certificate of Origin