I’m developing an web app in Arabic and i need to use a tree view to reprent my data. I looked around and found that jstree is the best in this area.
The tree works fine when using the default theme (which is LTR), but when i switched to a built-in theme called default-rtl, i didnt see any changes. I looked around in firebug and the script is indeed loading the appropriate css file. Here is my code:
$("#tree").bind("select_node.jstree", function(event, data) {
// My handler function here
}).bind("open_node.jstree", function (event, data) {
// another function here
}).jstree({
core: {
"animation": 0
},
"themes" : {
"rtl": true,
"theme" : "default-rtl",
"url": "js/libs/jstree/themes/default-rtl/style.css",
"dots" : false,
"icons" : true
},
"plugins" : [ "themes", "html_data", "ui"]
});
is there something I am doing wrong?
I managed to solve this issue.
I modifed this CSS file (attached) a little bit and included it in the
CSS folder that comes with JSTREE (usually it’s called default.css or
default-rtl). You can download it from here: http://www.mediafire.com/download.php?ah26sq0b0isbboa
Make sure you don’t have any
related to
your ul root element of ur tree
Hope that was clear,
Enjoy,