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

Translation list ordering ... list within a list?

1642292726

Edited 1642360360
Eric
Sheet Author
Hi, Working on my translated character sheet; I want to add list sorting on some of the lists. The ordering of the lists will need to reorder based on the language. On my sheet I have a list of Attributes  block items, and for each attribute there is a nested list of  Skill  block items.  So I need to sort the Attribute items, and then sort the Skill items within each Attribute item block. The attributes list items are listed in the translation file like this: "attribute-list": "agility,awareness,brawn,coordination,intelligence,personality,willpower", And the first two skill lists are like this: "skill-list-agility": "acrobatics,melee,stealth", "skill-list-awareness": "insight,observation,survival,thievery", And here is a slimmed down representation of the first couple attributes and skill blocks in the sheet HTML. <div data-i18n-list=" attribute-list "> <div data-i18n-list-item=" agility "> <div>AGILITY</div> <div data-i18n-list=" skill-list-agility ">                 <div data-i18n-list-item=" acrobatics "></div> <div data-i18n-list-item=" melee "></div> </div> </div> <div data-i18n-list-item=" awareness "> <div data-i18n-list=" skill-list-awareness ">                 <div data-i18n-list-item=" insight "></div> <div data-i18n-list-item=" observation "></div> </div> </div </div> Initially when I set up the Attribute items, the attribute blocks sorted nicely and were working good. Then once I added the nested skill items, the skill blocks will sort however the outer attribute blocks no longer sort. Should nested sort lists work, or is there a known reason it does not, or does my design look wrong? Thanks for reading.
1642303511

Edited 1642303556
vÍnce
Pro
Sheet Author
I've only created translation lists that were not nested.  Your code looks correct to me. Except for the incomplete </div 's ...  ;-) Maybe just a typo?
1642360302
Eric
Sheet Author
@ vÍnce  ... yeah, a victim of adhoc editing to slim down the code to just bare essentials (removing class attributes and content). I'm still struggling with the ability to sort a list within a sorted list. I can get either the outer or the inner to sort but not both at the same time. I'm sadly starting to think its not possible in roll20 translation abilities :(
1642365058
vÍnce
Pro
Sheet Author
I did a quick check on the repo to look at what other author's have done with "data-i18n-list" and didn't see any examples of "nesting".  You've likely found a limitation of the feature. ;-(
1642381007
Eric
Sheet Author
I just went to the Bug forum to report this and see someone else has the same issue here:&nbsp; <a href="https://app.roll20.net/forum/post/8392972/slug%7D" rel="nofollow">https://app.roll20.net/forum/post/8392972/slug%7D</a> Same issue, nested list. I also checked on my generated HTML page and after drilling waay down to where my list was I do see the error of an missing element 'undefined' on the outer list. Removing the inner list makes that error go away without any changes to it.
1642413708
Andreas J.
Forum Champion
Sheet Author
Translator
Eric said: I just went to the Bug forum to report this and see someone else has the same issue here:&nbsp; <a href="https://app.roll20.net/forum/post/8392972/slug%7D" rel="nofollow">https://app.roll20.net/forum/post/8392972/slug%7D</a> Submit a proper report through the help cente r and tell us what the ticket number will be. I try to maintain <a href="https://wiki.roll20.net/BCS/Bugs" rel="nofollow">https://wiki.roll20.net/BCS/Bugs</a> to track these kind of things.
1642446887
Eric
Sheet Author
Thanks, Andreas ... I created the bug report # 78138