Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

getAttr() error with i18n-list on "sheet!opned" event

Hi, I have a strange comportment with a input select using i18-list ordering, my code is this : <select name="attr_option_unit_move" data-i18n-list="option-unit-move-list">     <option value="1" data-i18n="option-unit-case" data-i18n-list-item="case"></option>     <option value="2" data-i18n="option-unit-feet" data-i18n-list-item="feet"></option>     <option value="3" selected="selected" data-i18n="option-unit-meter" data-i18n-list-item="meter"></option> </select> the translation.js file working correctly ( the select nput is ordered like i want). { "option-unit-move-list": "case,meter,feet" } using the character sheet with the ECMAscript has no problems; change value of the select trigger correctly the ECMAscript code. on( "sheet:opened", () => {     getAttrs( ["option_unit_move"], (user) => {         console.log(user.option_unit_move);     }); }); But when I create a new character, and  I open the sheet the previous code re return "1" ( I expected 3 ) I try to change the order of the option input, change the name of the ordered list but nothing wokr. I got the correct valye only if i remove the attribute data-i18n-list="option-unit-move-list"
an little update about this bug,it's seem to be related to nested ordering list, if the nested list is not a direct child to the parent ordered list. by example in this case : <ul data-i18n-list="listA">     <li data-i18n-list-item="item1">...</li>     <li data-i18n-list-item="item2">...<li>     <li data-i18n-list-item="item3">         <div>             <ul data-i18n-list="listB">                 <li data-i18n-list-item="item1">...</li>                 <li data-i18n-list-item="item2">...</li>             </ul>         </div>        <li> the two list are correctly ordered but listA return an error of an missing element 'undefined', and I got the error showed in the previous message maybe a bad iteration of data-i18n-list-item attribute ?