-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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: adds ability to copy data from across locales #8203
Conversation
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 good other than the error handling and translation todo. Nice work!
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.
I was going ot merge this but then I noticed there are a handful of missing translations to fix.
unsavedChanges: undefined,
Do you want to take care of that before I merge?
@DanRibbens undefined translations have been fixed 👍 |
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.
I tried to test the feature with blocks and it errored for me.
This was taken from our test/localization suite working with the Nested Arrays collection.
I'm not sure if this is because the collection has versions enabled or if it was nested data that couldn't be handled.
Aside from this, I have UX concerns about this feature as it would be too easy for a user to click the wrong locale and overwrite some existing data. It feels to me like we should have a modal or something to add an additional step for acknowledging that they might be overwriting everything in a document on the target locale.
The copy button should look more like a secondary actions with dropdown options like this:
copy button appears and was moved into actions popup
🚀 This is included in version v3.2.0 |
What?
Adds ability to copy data from one locale to another at a document level.
Feature request can be found here.
[Internal] Design here.
How?
For any localized collection, you will find a new option in the document controls called
Copy to Locale
.This option will open a drawer, from here you can select your origin and destination locales.
If data already exists in the destination locale, you can choose to:
You can change your selection using the following checkbox: