PHP Classes

File: framework/resources/js/components/tree.js

Recommend this page to a friend!
  Classes of Saro Carvello   PHP Web MVC Framework   framework/resources/js/components/tree.js   Download  
File: framework/resources/js/components/tree.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: PHP Web MVC Framework
MVC framework providing autogenerated MySQL models
Author: By
Last change:
Date: 11 months ago
Size: 543 bytes
 

Contents

Class file image Download
/* Framework JS code for tree component */ (function ($) { "use strict"; var toggle = function (ev) { $("> ul", this).toggle(); // TODO: use animation instead ev.stopPropagation(); // don't toggle parent }; var tree = function (i, node) { // TODO: rename var root = $(this); // $("ul", root).hide(); // TODO: optional $("li", root).click(toggle); }; $.fn.tree = function (options) { options = options || {}; // XXX: unused this.each(tree); }; }(jQuery));