Hi there. Thanks for sharing this plugin, it has been a great addition to our Sanity setup.
I have encountered an issue where a user can accidentally create duplicate translations of the same document from the “Translations” menu by clicking the same “+ {language}” button multiple times before the translated document has been created.
This can be reproduced in the following steps:
Create a base Sanity project with a single document type, e.g. page
Install the plugin, and configure Sanity to translate the document as per the plugin instructions.
Create a document in one language
Create a document translation via the “+ {language}” button in the “Translations” menu, and then click the same button again immediately after.
For each click until the first translated document is returned, a duplicate document will be created.
It would be helpful to have a solution where when adding a translation, the “+ {language}” button is disabled after the first click until the translated document is created.
Hi there. Thanks for sharing this plugin, it has been a great addition to our Sanity setup.
I have encountered an issue where a user can accidentally create duplicate translations of the same document from the “Translations” menu by clicking the same “+ {language}” button multiple times before the translated document has been created.
This can be reproduced in the following steps:
page
See video for demonstration.
https://github.com/sanity-io/document-internationalization/assets/42866396/9fc87a26-435b-4341-8731-7bea5e0fb309
It would be helpful to have a solution where when adding a translation, the “+ {language}” button is disabled after the first click until the translated document is created.