IronOS icon indicating copy to clipboard operation
IronOS copied to clipboard

help with TranslationEditor needed

Open discip opened this issue 1 year ago • 1 comments

  1. I would like to know if there is a way to change the TranslationEditor to generate this:

     "SolderingMenu": {
       "text2": ["Soldering", "settings"],
       "desc": "Soldering settings"
     },
    

    instead of this:

     	"SolderingMenu": {
     		"text2": [
     			"Soldering",
     			"settings"
     		],
     		"desc": "Soldering settings"
     	},
    
  2. I rearranged some of the menu entries in translation_EN.json, edited translations_def.js & Translation.h accordingly and wanted to use TranslationEditor to change all the other languages as well, so I would not have to do it by hand.

    translation_EN.json was used as Reference Language. And although the html view was matching the new order, the saved file and view, unfortunately maintained the old order!

@discip its would be better to put this into its own issue than bumping a really old thread. I cant see any difference between the two you have posted other than formatting, so you might need to clarify what the difference is that you are looking for as well

Originally posted by @Ralim in https://github.com/Ralim/IronOS/pull/249#issuecomment-1244938277

  1. other than formatting

    Yes, that's exactly it! Only the format. The actual one takes up much space (scrolling wise). Some languages were formatted like that (narrower) before I updated them to match the output of TranslationEditor.

  2. Sorry, I don't know how to make a visual comparison between the two. 😅

    actual one: https://github.com/Ralim/IronOS/blob/dev/Translations/translation_EN.json vs reordered one: https://github.com/discip/IronOS/blob/test/Translations/translation_EN.json

discip avatar Sep 14 '22 20:09 discip

@Ralim Have you had time to check if this is somehow achievable? 😊

discip avatar Sep 20 '22 16:09 discip

I dont know to be honest; this is going to come down to how javascript is serialising it out. As its just a formatting change, I dont see the big issue though?

Ralim avatar Sep 24 '22 07:09 Ralim

@Ralim Is your answer meant to cover both topics?

It would really help if I could use TranslationEditor to make editing all the language files easier. (2)

discip avatar Sep 27 '22 14:09 discip