(function() {
  define(["./dom"], function(dom) {
    dom.onDocument("click", "[data-behavior=stack-trace-filter-toggle]", function() {
      var checked, i, len, ref, traceList;
      checked = this.element.checked;
      ref = dom.body.find(".stack-trace");
      for (i = 0, len = ref.length; i < len; i++) {
        traceList = ref[i];
        traceList[checked ? "addClass" : "removeClass"]("filtered");
      }
    });
    return null;
  });

}).call(this);
