Project

General

Profile

Idea #15071

Updated by Lucas Di Pentima over 5 years ago

Based on our previous format, for example: 

 <pre> 
 { 
     "strict": false, 
     "tags": { 
         "fruit": { 
             "values": ["pineapple", "tomato", "orange", "banana", "advocado", "lemon", "apple", "peach", "strawberry"], 
             "strict": true 
         }, 
         "comments": {}, 
         "importance": { 
             "values": ["critical", "important", "low priority"] 
         } 
     } 
 } 
 </pre> 

 ...where @strict: false@ was needed to be able to express when the user is permitted to add arbitrary text on keys and/or values, we now need to support multiple labels for a single concept, and the possibility to add translations too, the proposed format would be: 

 <pre> 
 { 
     "strict": false, 
     "tags": { 
         "ID1234567890": { 
             "strict": true, 
             "labels": { 
                 "default": ["fruit", "Fruit"], 
                 "es-ES": ["fruta", "Fruta"], 
                 "zh-CN": ["水果", "果"] 
             }, 
             "values": { 
                 "pineapple": { 
                     "es-ES": "piña", 
                     "es-AR": "ananá", 
                     "zh-CN": "菠萝" 
                 }, 
                 ... 
             } 
         }, 
         "ID1234567891": { 
             "labels": { 
                 "default": ["comment", "suggestion"] 
             } 
         }, 
         "ID1234567892": { 
             "labels": { 
                 "default": ["importance"] 
             }, 
             "values": { 
                 "critical": {}, 
                 "important": {}, 
                 ... 
             } 
         } 
     } 
 } 
 </pre> 

 Of course, this would be useful as a "forward-index", enabling the UI to show the correct data. The UI should be creating a reverse index for data input.

Back