jhfrench / bootstrap-tree Goto Github PK
View Code? Open in Web Editor NEWJavaScript and LESS/CSS for creating Bootstrap-themed trees (to display hierarchical data).
JavaScript and LESS/CSS for creating Bootstrap-themed trees (to display hierarchical data).
Hey
I need to ask how to get multi-select configured in this bootstrap-tree ?
Running "less:dev" (less) task
Running "less:prod" (less) task
NameError: variable @BaseBorderRadius is undefined in less\bootstrap-tree.less on line 3, column 15:
2 .tree {
3 .border-radius(@BaseBorderRadius);
4 .box-shadow(inset 0 1px 1px rgba(0,0,0,.05));
Warning: Error compiling LESS. Use --force to continue.
Aborted due to warnings.
How would I start the folder list as closed instead of all open?
what would be the best way to move the items to a new branch in the tree through draggable capabilities?
Hi Jeromy,
I would like to suggest a modification to the styling, as I had pointed out in my comment here.
It seemed a bit buggy to me initially when I first saw it all those months ago, but I let it pass. I noticed your repo today, and thought I'll have a look. The tree is absolutely fantastic, except that one niggle which I just can't shake, so I thought I'd rather raise this issue for you to consider.
Thanks for your patience.
-- khs
This not actually an issue, but havn't yet found a way to comment on github
Just wanted to say that it looks great. I see no other issues etc listed here so wanted to pass a comment to show there is interested out there in case it motivates you take it further. Every few months I scan looking for a bootstrap tree - saw this on stackoverflow - currently using ajaxtree which isn't bootstrap styled but does what I need it to.
Yours looks awesome. I do need the javascript functionality of ajaxtree, so hoping someone else merges yours with ajaxtree before I need to :). I have nested sets and adjacency lists all over the place within my current project (yii php) and surprised there isn't already more good code out there for trees - a tingle of excitement after coming across yours.
Amazing all that achieved in just css!
Cheers
http://caniuse.com/#search=%3A%3A
the use of "::" pseudo-selectors arent viable to all browsers.and is depricated.
bootstrap-tree
which will need to be forked for this.<pre>
rendering of result failure description by a <p>
with, perhaps, <br>
s mapping to the new lines in the description. Aside of not looking that good, the <pre>
somehow breaks the tree lines.This really ins't an issue but I wanted to contribute. I found your code but needed to do expand and collapse all. I ended up writing these two functions:
function toggleSingleElement(el){
var children = $(el).parent('li.parent_li').find(' > ul > li');
if (children.is(":visible")) {
children.hide('fast');
$(el).attr('title', 'Expand this branch').find(' > i').addClass('icon-plus-sign').removeClass('icon-minus-sign');
} else {
children.show('fast');
$(el).attr('title', 'Collapse this branch').find(' > i').addClass('icon-minus-sign').removeClass('icon-plus-sign');
}
}
function globalToggle(element, selector){
var addClass;
var removeClass;
var title;
if($(element).find(' > i').hasClass('icon-minus-sign')){
addClass = 'icon-plus-sign';
removeClass = 'icon-minus-sign';
title = 'Expand this branch';
}else{
addClass = 'icon-minus-sign';
removeClass = 'icon-plus-sign';
title = 'Collapse this branch';
}
$(element).attr('title', title).find(' > i').addClass(addClass).removeClass(removeClass);
$(selector).each(function (index, value) {
console.log('span' + index + ':' + $(this).attr('id'));
toggleSingleElement(this);
});
}
Then I added the following to my document ready:
$('.tree li:has(ul)').addClass('parent_li').find(' > span').attr('title', 'Collapse this branch');
$('.tree li.parent_li > span').on('click', function (e) {
toggleSingleElement(this);
e.stopPropagation();
});
$('.app-toggle').on('click', function (e) {
globalToggle(this ,'.app-element');
e.stopPropagation();
});
$('.device-toggle').on('click', function (e) {
globalToggle(this ,'.device-element');
e.stopPropagation();
});
please add bower bootstrap tree
<code>
snippets after examplesDear Team,
Is there checkbox support for this tree?
I have a requirement to populate tree-view dynamically and tree-view should have check-boxes so that User can check some nodes and in the back-end I have to get those nodes that are checked.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.