# UX Importer for Unity UI Toolkit ## Description **UX Importer for Unity UI Toolkit** is a toolset for converting UI designs created in **external design platforms** into Unity's UI Toolkit format (UXML and USS). It consists of the **UX Exporter plugin** and a Unity editor extension, smoothing the collaboration between designers and developers. Export a JSON file with all scene information and necessary asset files as a ZIP using the **UX Exporter plugin**. Simply import that ZIP file into your Unity project to faithfully reproduce the layout from the original design. Please obtain the UX Exporter plugin here. https://bamboo-up.app/ ## Workflow 1. **Design Creation**: * The designer creates the UI design in the external design platform. 2. **Design Export**: * Use the **UX Exporter plugin** (available for download at [https://bamboo-up.app/](https://bamboo-up.app/)) to export the design as a **ZIP file containing the JSON data and required image assets**. 3. **Placement in Unity Project**: * **Unzip** the exported ZIP file and place its contents (the JSON file and assets) into any folder within your Unity project (e.g., `Assets/DesignExports/`). 4. **Scene Setup (DataHub Root)**: * In your Unity scene, add a new GameObject and attach the **`DataHub Root` component** to it. This component is essential for centralizing references to Addressables and Localization data, and it will serve as the **parent object for the generated UI structure**. 5. **UXML/USS Automatic Generation**: * After Unity recognizes the JSON file, launch the tool from the editor menu: `Window/BambooUp studio/UX Importer for UUIT`. * Within the tool, specify the JSON file to automatically generate the **UXML and USS stylesheets** ready for use with the UI Toolkit. ## Tool Configuration The following settings must be configured within the GUI of the "UX Importer for Unity UI Toolkit" import tool. ### 1. Input Settings | Item | Description | | :--- | :--- | | **JSON File** | Specify the JSON file containing the design information exported by the UX Exporter plugin. | ### 2. Output Settings | Item | Description | | :--- | :--- | | **Output Folder** | Specify the project folder where the generated **UXML files**, **USS stylesheets**, and **DataHub files** will be saved. | | **DataHub Root Reference** | Specify the **`DataHub Root` component** placed in your scene. The generated UI will be structured as a child of this root. | ### 3. Localization Settings | Item | Description | | :--- | :--- | | **Localization Asset Folder** | Specify the folder where **assets like String Tables** generated by the Unity Localization package will be stored. | ### 4. Font Settings | Item | Description | | :--- | :--- | | **Default Font** | Specify a default font asset to be used as a substitute if a font utilized in the original design cannot be found in the Unity project. | *** ## Operations (Import and Undo) | Operation | Description | | :--- | :--- | | **Execute Import** | Reads the JSON file based on the settings above and generates the UXML/USS and associated assets. | | **Undo Import** | Reverts (deletes) the results of the last executed import operation (UXML/USS and DataHub files, etc.) from the specified output folder. |