jdorn / json-editor

JSON Schema Based Editor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Tree Mode - selecting jsoneditor-contextmenu on array element blanks current value of element

Kopll opened this issue · comments

commented

Hi
When clicking on the context-menu icon in tree mode next to an array element that already has the loaded value of STRINGVAL and is rendered on screen as STRINGVAL

The underlying value is changed from "STRINGVAL" to "" - Validated this elements in memory representation is defiantly "" by inspecting the data structure in codeview & textview

User has to select another pre populated value from enum list (say STRINGVALTWO) and then select the original STRINGVAL again to set the correct value - makes for a clunky interface and not immediately apparent to user there is an issue as the Value is still rendered on screen.

schema: for array
"ALERTGROUP": {
"type": "array",
"uniqueItems": true,
"minItems": 1,
"items": {
"type": "string",
"minItems": 1,
"enum": [
"TEST",
"MTS",
"DST",
"BBSW",
"TAMS",
"ORMB",
"TOPS",
"GCS",
"PST",
"TRANS"
],
"default": "MTS"
}
},
contextmenu-click_codeview
contextmenu-click_treeview

Thanks

Jimmy

Hello,

Please view this page: https://github.com/josdejong/jsoneditor

Obs*: you created the issue in wrong repository.