{"id":16643425,"url":"https://github.com/sonots/ancestry-treeview","last_synced_at":"2025-08-22T17:03:07.889Z","repository":{"id":9104379,"uuid":"10884668","full_name":"sonots/ancestry-treeview","owner":"sonots","description":"extension of ancestry gem to show tree view","archived":false,"fork":false,"pushed_at":"2013-07-04T13:26:03.000Z","size":156,"stargazers_count":8,"open_issues_count":1,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-06T19:02:13.985Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sonots.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-06-23T13:12:55.000Z","updated_at":"2018-09-22T23:46:48.000Z","dependencies_parsed_at":"2022-09-23T08:40:46.572Z","dependency_job_id":null,"html_url":"https://github.com/sonots/ancestry-treeview","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonots%2Fancestry-treeview","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonots%2Fancestry-treeview/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonots%2Fancestry-treeview/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonots%2Fancestry-treeview/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sonots","download_url":"https://codeload.github.com/sonots/ancestry-treeview/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238961151,"owners_count":19559428,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-12T08:08:29.153Z","updated_at":"2025-02-15T07:32:41.061Z","avatar_url":"https://github.com/sonots.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ancestry-treeview [![Build Status](https://secure.travis-ci.org/sonots/ancestry-treeview.png?branch=master)](http://travis-ci.org/sonots/ancestry-treeview) [![Dependency Status](https://gemnasium.com/sonots/ancestry-treeview.png)](https://gemnasium.com/sonots/ancestry-treeview)\n\ntesting ruby: 1.9.3, 2.0.0; ancestry: 2.0.0\n\nancestry-treeview is an extension of `ancestry` gem to show a tree view which looks like http://jsfiddle.net/Fh47n/.\n\n## Install\n\n    gem install ancestry-treeview\n\n## Usage\n\n### Basic Usage\n\nAdd the following code in your `app/assets/stylesheets/application.css.scss`\n\n    @import \"ancestry-treeview\";\n\nThen, call\n\n    node.tree\n\nin your view where `node` is your `ancestry` model. \n\n### Custom Link\n\nDefault html links in the tree view are as\n\n    \u003ca href=\"#\"\u003eid\u003c/a\u003e\n    \nYou can change the html link by giving a block as\n\n    node.tree {|node| link_to(\"text\", your_controller_path(node)) }\n\n### Contraint Depth\n\nAs default, all childrens of a node is shown as a tree. Use `to_depth` option to contraint the depth\n\n    node.tree(to_depth: 1)\n\n## Acknowledgements\n\nI appreciate Vitaliy Bychik for giving such a nice css style at http://stackoverflow.com/questions/11167628/trees-in-twitter-bootstrap .\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new [Pull Request](../../pull/new/master)\n\n## Copyright\n\nCopyright (c) 2013 Naotoshi SEO. See [LICENSE](LICENSE) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsonots%2Fancestry-treeview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsonots%2Fancestry-treeview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsonots%2Fancestry-treeview/lists"}