Difference between revisions of "Figma to Dev Generation Details"
| Line 1: | Line 1: | ||
| − | =Introduction= |
||
== Figma Projects: For UI/UX designers == |
== Figma Projects: For UI/UX designers == |
||
| Line 18: | Line 17: | ||
Software developers can benefit from having resource files generated from the Figma Projects directly in a repository and format of their choice. Key value pairs for the resource files can be generated from the source and target strings of the Localyzer Figma project. To create a Figma to Dev project, see: [[Create_a_Localyzer_only_project#Figma_to_Dev]] |
Software developers can benefit from having resource files generated from the Figma Projects directly in a repository and format of their choice. Key value pairs for the resource files can be generated from the source and target strings of the Localyzer Figma project. To create a Figma to Dev project, see: [[Create_a_Localyzer_only_project#Figma_to_Dev]] |
||
| + | Developers files are typically resx, properties, JSON, .strings, strings.xml files. |
||
| − | == Changes in Figma projects or Software projects== |
||
| + | |||
| + | == Edits in Figma projects or Software projects== |
||
After initial translation of Figma project and generation of developer resource files, changes may occur in either. What happens to the generated resources for developers? |
After initial translation of Figma project and generation of developer resource files, changes may occur in either. What happens to the generated resources for developers? |
||
| + | Below, we call Developer files -properties, resx, json, etc.- files generated from Figma projects. |
||
| − | == Source Locale == |
||
== Who wins? == |
== Who wins? == |
||
Here are some scenarios that may occur when editing both Figma and LRM resource files: |
Here are some scenarios that may occur when editing both Figma and LRM resource files: |
||
| − | * Key in Figma base file has changed since last time generation was run -> '''Figma wins''' |
+ | * Key in Figma base file has changed since last time generation was run -> '''Figma wins''' the Developer file is overwritten |
| − | * Key in Figma target file has changed since last time generation was run -> '''Figma wins''' |
+ | * Key in Figma target file has changed since last time generation was run -> '''Figma wins''' the Developer files are overwritten |
| − | * Developer changed a Figma key in the |
+ | * Developer changed a Figma key in the Dev resource file and the change was imported -> '''Developer wins''' |
** However, the changes will be overlayed once a Figma file has changed for the same key |
** However, the changes will be overlayed once a Figma file has changed for the same key |
||
| − | * Both Figma base file and its corresponding Figma target file have changed since last time generation was run -> '''Figma wins''' |
+ | * Both Figma base file and its corresponding Figma target file have changed since last time generation was run -> '''Figma wins''' the Developer files are overwritten |
| − | ** After the conversion both the |
+ | ** After the conversion both the Figma resource base file and target file have changed |
** There will be no NOT_IN_LRM error that usually occurs when both the base and target files have the same new key. |
** There will be no NOT_IN_LRM error that usually occurs when both the base and target files have the same new key. |
||
Revision as of 20:24, 26 November 2025
Contents
Figma Projects: For UI/UX designers
Designers create interfaces in Figma, use the Figma Lingoport Plugin to push the strings to a Localyzer Figma Project. Those Figma strings can be translated. The translations can be shown in Figma using the Figma Lingoport plugin.
The Figma strings are kept in a repository. This repository is not for developers, it is only for Localyzer.
In the Figma repository, files are located in 'figma/locales/<locale>/translation.json'. For example:
- figma/locales/en/translation.json
- figma/locales/fr/translation.json
In the Figma project, keys are created. Those keys will be used to generate the key/value pairs for Figma2Dev project. Keys are located under:
- figma/locales/keys/translation.json
Source strings, translated strings, and keys are all visible from Figma using the Figma Lingoport Plugin.
Figma2Dev Projects: For software developers
Software developers can benefit from having resource files generated from the Figma Projects directly in a repository and format of their choice. Key value pairs for the resource files can be generated from the source and target strings of the Localyzer Figma project. To create a Figma to Dev project, see: Create_a_Localyzer_only_project#Figma_to_Dev
Developers files are typically resx, properties, JSON, .strings, strings.xml files.
Edits in Figma projects or Software projects
After initial translation of Figma project and generation of developer resource files, changes may occur in either. What happens to the generated resources for developers?
Below, we call Developer files -properties, resx, json, etc.- files generated from Figma projects.
Who wins?
Here are some scenarios that may occur when editing both Figma and LRM resource files:
- Key in Figma base file has changed since last time generation was run -> Figma wins the Developer file is overwritten
- Key in Figma target file has changed since last time generation was run -> Figma wins the Developer files are overwritten
- Developer changed a Figma key in the Dev resource file and the change was imported -> Developer wins
- However, the changes will be overlayed once a Figma file has changed for the same key
- Both Figma base file and its corresponding Figma target file have changed since last time generation was run -> Figma wins the Developer files are overwritten
- After the conversion both the Figma resource base file and target file have changed
- There will be no NOT_IN_LRM error that usually occurs when both the base and target files have the same new key.
Figma -> Dev generation restrictions
- There can be no outstanding prep kits
- Parser type must support generation. The following parser types do not support Figma -> Dev generation.
- text
- binary
- html
- xhtml
- Parser types such as json or yaml cannot have language or global tags defined