Skip to content

Avoid duplicating warning in ng-repeat #91

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
.idea/

6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Use the following syntax:

The data to create the tree is defined in your controller, and could be as simple as this:

$scope.my_data = [{
$scope.my_treedata = [{
label: 'Languages',
children: ['Jade','Less','Coffeescript']
}]
Expand All @@ -66,7 +66,7 @@ long-form, where is branch is an object, then you can also attach "data" to a br

If you would like to add classes to a certain node, give it an array of classes like so:

$scope.my_data = [{
$scope.my_treedata = [{
label: 'Languages',
children: ['Jade','Less','Coffeescript']
classes: ["special", "red"]
Expand All @@ -86,7 +86,7 @@ You can supply a single default "on-select" function for the whole tree -- it wi

Or, you can put a custom "on-select" function on an individual branch:

$scope.my_data = [{
$scope.my_treedata = [{
label: 'Languages',
onSelect: function(branch){...},
children: ['Jade','Less','Coffeescript']
Expand Down
2 changes: 1 addition & 1 deletion dist/abn_tree_directive.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
{
"name": "angular-bootstrap-nav-tree",
"version": "0.2.0",
"repository":{
"type":"git",
"url":"git://github.com/nickperkinslondon/angular-bootstrap-nav-tree"
},
"dependencies": {},
"devDependencies": {
"grunt": "~0.4.1",
Expand All @@ -10,5 +14,5 @@
"grunt-string-replace": "~0.2.7"
},
"keywords":["angularjs","bootstrap","tree","widget"],
"licence":"MIT"
"license":"MIT"
}
2 changes: 1 addition & 1 deletion src/abn_tree_template.jade
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
ul.nav.nav-list.nav-pills.nav-stacked.abn-tree

li.abn-tree-row(
ng-repeat='row in tree_rows | filter:{visible:true} track by row.branch.uid'
ng-repeat='row in tree_rows | filter:{visible:true} track by row.branch.uid || \'~\' + $index'
ng-animate="'abn-tree-animate'"
ng-class="'level-' + {{ row.level }} + (row.branch.selected ? ' active':'') + ' ' +row.classes.join(' ')"
)
Expand Down