-
Notifications
You must be signed in to change notification settings - Fork 400
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(structure): allow sanity.previewUrlSecret in document lists #5733
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
2d73609
to
8184399
Compare
No changes to documentation |
Component Testing Report Updated Feb 15, 2024 5:01 PM (UTC)
|
juice49
reviewed
Feb 14, 2024
8184399
to
0fbdefc
Compare
0fbdefc
to
2d1c985
Compare
juice49
approved these changes
Feb 15, 2024
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.
Looks great to me! 🚀 Just need to sync the branch with next
.
Signed-off-by: Fred Carlsen <fred@sjelfull.no>
2d1c985
to
9589446
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
The #5657 PR didn't manage to fix the regression in #5440. With the help of @sjelfull this time it's actually resolved and the fix reproducible on the Test Studio.
What to review
Adding
sanity.previewUrlSecret
should only have an effect on this particular type, othersanity.
prefixed types shouldn't show up anywhere, like in global search.Testing
In a Studio that has this plugin installed:
Then Structure tool should show this menu:
![image](https://private-user-images.githubusercontent.com/81981/304754580-129c218d-7d33-4b89-be10-10d0888921aa.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTkxNjI3NTMsIm5iZiI6MTcxOTE2MjQ1MywicGF0aCI6Ii84MTk4MS8zMDQ3NTQ1ODAtMTI5YzIxOGQtN2QzMy00Yjg5LWJlMTAtMTBkMDg4ODkyMWFhLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MjMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjIzVDE3MDczM1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTBjNzkxZDcxMzFhNTU0Y2NiYTRkZmNjYzllZjkyMWI4N2VhYTYyYzRlNTgzODRlYTMwMGY2YmE5MGRiMzU3OTAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.9iplkDuG_OmM43TtPI29PrGx9U-1Oqy_lquyxCZDwYE)
![image](https://private-user-images.githubusercontent.com/81981/304755170-ef4c27d5-ecf1-45f9-90b3-795e956228af.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTkxNjI3NTMsIm5iZiI6MTcxOTE2MjQ1MywicGF0aCI6Ii84MTk4MS8zMDQ3NTUxNzAtZWY0YzI3ZDUtZWNmMS00NWY5LTkwYjMtNzk1ZTk1NjIyOGFmLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MjMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjIzVDE3MDczM1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPThiMWM5MDU3YWNkNTEwZmQ3ZjgzYTk5NGQ2YzBiZjc5NjdjMTUwMjQxNDQ3ZjE5NWQwYjQ5M2UyMzViZDU0ZjEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.nItO5khufeWQE1vXIdECXkeTMRknJk4DlVzycilOsOo)
And global search should let you filter by the type as well:
When the plugin isn't used then these document types should remain hidden:
![image](https://private-user-images.githubusercontent.com/81981/304755546-95c197ae-9c0e-4cd7-87c3-cfc5e2fc98e6.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTkxNjI3NTMsIm5iZiI6MTcxOTE2MjQ1MywicGF0aCI6Ii84MTk4MS8zMDQ3NTU1NDYtOTVjMTk3YWUtOWMwZS00Y2Q3LTg3YzMtY2ZjNWUyZmM5OGU2LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MjMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjIzVDE3MDczM1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTFhOGM5OWU5MjY0NWZiY2E0ZjdiNGNhNzI3NDcxMGM5MTAzNGEzZmY0MzFmYjg3ZTE2N2IxMTk0N2UxNjFmMmMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.7tdfXcy-FiJyO6yNMQE8KLwJ1zzJAmnAbXtI5kyhwhY)
Notes for release
import {debugSecrets} from '@sanity/preview-url-secret/sanity-plugin-debug-secrets'
from listing secrets