You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kibble.apache.org by hu...@apache.org on 2018/08/03 13:54:36 UTC

[kibble] 03/03: regen JS

This is an automated email from the ASF dual-hosted git repository.

humbedooh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kibble.git

commit 8b3f6d5137fa4b8a4c088b39df2499738e779f1d
Author: Daniel Gruno <hu...@apache.org>
AuthorDate: Fri Aug 3 15:54:18 2018 +0200

    regen JS
---
 ui/js/kibble.v1.js | 112 ++++++++++++++++++++++++++---------------------------
 1 file changed, 56 insertions(+), 56 deletions(-)

diff --git a/ui/js/kibble.v1.js b/ui/js/kibble.v1.js
index 35fec4c..f7bfe90 100644
--- a/ui/js/kibble.v1.js
+++ b/ui/js/kibble.v1.js
@@ -1,4 +1,4 @@
-// Generated by CoffeeScript 1.10.0
+// Generated by CoffeeScript 1.12.7
 var API, APIVERSION, Chart, HTML, Row, Widget, aSourceTypes, accountCallback, addSourceType, addSources, addorguser, addsources, affiliate, affiliation, affiliationWizard, altemail, app, badModal, bio, chartOnclick, chartToSvg, chartWrapperButtons, charts_donutchart, charts_gaugechart, charts_linechart, charts_linechart_stacked, charts_linked, charts_radarchart, ciexplorer, cog, comShow, comstat, copyCSS, currentSources, dataTable, datepicker, datepickers, defaultOrgChanged, deletesource [...]
   indexOf = [].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; };
 
@@ -238,9 +238,9 @@ charts_linechart_stacked = (function(_this) {
 })(this);
 
 charts_linechart = function(obj, data, options) {
-  var a, aa, asDataArray, asList, asTypes, axisData, c, config, dataPoint, dateFormat, el, k, key, len, len1, len2, linetype, ndate, q, ref, ref1, stacked, tmpArray, ts, u, v, val, xts, xx;
-  linetype = options && options.linetype ? options.linetype : 'line';
-  stacked = options && options.stacked ? options.stacked : false;
+  var a, asDataArray, asList, asTypes, axisData, c, config, dataPoint, dateFormat, el, i1, k, key, len, len1, len2, linetype, ndate, q, ref, ref1, stacked, tmpArray, ts, u, v, val, xts, xx;
+  linetype = (options && options.linetype) ? options.linetype : 'line';
+  stacked = (options && options.stacked) ? options.stacked : false;
   if (options && options.filled && linetype === "line") {
     linetype = "area-spline";
   }
@@ -313,15 +313,15 @@ charts_linechart = function(obj, data, options) {
     }
     asDataArray = ts;
   } else {
-    ref1 = data.counts;
+    ref1 = data.counts || data.phrases;
     for (k in ref1) {
       v = ref1[k];
       asList.push(k);
       asTypes[k] = 'bar';
       tmpArray = [k];
       if (isArray(v)) {
-        for (aa = 0, len2 = v.length; aa < len2; aa++) {
-          dataPoint = v[aa];
+        for (i1 = 0, len2 = v.length; i1 < len2; i1++) {
+          dataPoint = v[i1];
           tmpArray.push(dataPoint);
         }
       } else {
@@ -598,7 +598,7 @@ charts_linked = function(obj, nodes, links, options) {
 };
 
 charts_radarchart = function(obj, data, options) {
-  var Format, LegendOptions, aa, ab, axes, axis, cfg, d, el, g, i, indicator, j, legend, len, len1, levelFactor, li, q, radius, rect, ref, ref1, ref2, ref3, series, tooltip, total, u;
+  var Format, LegendOptions, axes, axis, cfg, d, el, g, i, i1, indicator, j, j1, legend, len, len1, levelFactor, li, q, radius, rect, ref, ref1, ref2, ref3, series, tooltip, total, u;
   cfg = {
     radius: 5,
     w: 360,
@@ -658,7 +658,7 @@ charts_radarchart = function(obj, data, options) {
   d3.select(obj).select("svg").remove();
   rect = obj.getBoundingClientRect();
   g = d3.select(obj).append("svg").attr("preserveAspectRatio", "xMinYMin meet").attr("viewBox", "0 0 1000 500").append("g").attr("transform", "translate(" + cfg.TranslateX + "," + cfg.TranslateY + ")");
-  for (j = aa = 0, ref2 = cfg.levels; 0 <= ref2 ? aa < ref2 : aa > ref2; j = 0 <= ref2 ? ++aa : --aa) {
+  for (j = i1 = 0, ref2 = cfg.levels; 0 <= ref2 ? i1 < ref2 : i1 > ref2; j = 0 <= ref2 ? ++i1 : --i1) {
     levelFactor = cfg.factor * radius * ((j + 1) / cfg.levels);
     g.selectAll(".levels").data(axes).enter().append("svg:line").attr("x1", (function(_this) {
       return function(d, i) {
@@ -678,7 +678,7 @@ charts_radarchart = function(obj, data, options) {
       };
     })(this)).attr("class", "line").style("stroke", "grey").style("stroke-opacity", "0.75").style("stroke-width", "0.3px").attr("transform", "translate(" + (cfg.w / 2 - levelFactor) + ", " + (cfg.h / 2 - levelFactor) + ")");
   }
-  for (j = ab = 0, ref3 = cfg.levels; 0 <= ref3 ? ab < ref3 : ab > ref3; j = 0 <= ref3 ? ++ab : --ab) {
+  for (j = j1 = 0, ref3 = cfg.levels; 0 <= ref3 ? j1 < ref3 : j1 > ref3; j = 0 <= ref3 ? ++j1 : --j1) {
     levelFactor = cfg.factor * radius * ((j + 1) / cfg.levels);
     g.selectAll(".levels").data([1]).enter().append("svg:text").attr("x", (function(_this) {
       return function(d) {
@@ -726,10 +726,10 @@ charts_radarchart = function(obj, data, options) {
     });
     dataValues.push(dataValues[0]);
     g.selectAll(".area").data([dataValues]).enter().append("polygon").attr("class", "radar-chart-serie" + series).style("stroke-width", "2px").style("stroke", cfg.color[series]).attr("points", function(d) {
-      var ac, len2, pt, str;
+      var k1, len2, pt, str;
       str = "";
-      for (ac = 0, len2 = d.length; ac < len2; ac++) {
-        pt = d[ac];
+      for (k1 = 0, len2 = d.length; k1 < len2; k1++) {
+        pt = d[k1];
         str = str + pt[0] + "," + pt[1] + " ";
       }
       return str;
@@ -956,7 +956,7 @@ copyCSS = function(destination, source) {
 };
 
 downloadBlob = function(name, uri) {
-  var blob, e, error, saveLink, url;
+  var blob, e, saveLink, url;
   if (navigator.msSaveOrOpenBlob) {
     return navigator.msSaveOrOpenBlob(uriToBlob(uri), name);
   } else {
@@ -1131,7 +1131,7 @@ Chart = (function() {
     this.main.inject(this.toolbar);
     this.titlebar = new HTML('div', {
       "class": "chartTitle"
-    }, options && options.title ? options.title : "");
+    }, (options && options.title) ? options.title : "");
     this.main.inject(this.titlebar);
     i = 0;
     chartWrapperColors = genColors(16, 0.2, 0.75, true);
@@ -3062,7 +3062,7 @@ fetch = function(url, xstate, callback, nocreds) {
   xmlHttp.open("GET", "api/" + url, true);
   xmlHttp.send(null);
   return xmlHttp.onreadystatechange = function(state) {
-    var e, error, js, mpart, response;
+    var e, js, mpart, response;
     if (xmlHttp.readyState === 4 && xmlHttp.status === 500) {
       if (snap) {
         snap(xstate);
@@ -3109,7 +3109,7 @@ put = function(url, json, xstate, callback, nocreds) {
   xmlHttp.open("PUT", "api/" + url, true);
   xmlHttp.send(JSON.stringify(json || {}));
   return xmlHttp.onreadystatechange = function(state) {
-    var e, error, js, response;
+    var e, js, response;
     if (xmlHttp.readyState === 4 && xmlHttp.status === 500) {
       if (snap) {
         snap(xstate);
@@ -3156,7 +3156,7 @@ patch = function(url, json, xstate, callback, nocreds) {
   xmlHttp.open("PATCH", "api/" + url, true);
   xmlHttp.send(JSON.stringify(json || {}));
   return xmlHttp.onreadystatechange = function(state) {
-    var e, error, js, response;
+    var e, js, response;
     if (xmlHttp.readyState === 4 && xmlHttp.status === 500) {
       if (snap) {
         snap(xstate);
@@ -3203,7 +3203,7 @@ xdelete = function(url, json, xstate, callback, nocreds) {
   xmlHttp.open("DELETE", "api/" + url, true);
   xmlHttp.send(JSON.stringify(json || {}));
   return xmlHttp.onreadystatechange = function(state) {
-    var e, error, js, response;
+    var e, js, response;
     if (xmlHttp.readyState === 4 && xmlHttp.status === 500) {
       if (snap) {
         snap(xstate);
@@ -3261,7 +3261,7 @@ post = function(url, json, xstate, callback, snap) {
   xmlHttp.setRequestHeader("Content-type", "application/json");
   xmlHttp.send(fdata);
   return xmlHttp.onreadystatechange = function(state) {
-    var e, error, response;
+    var e, response;
     if (xmlHttp.readyState === 4 && xmlHttp.status === 500) {
       if (snap) {
         snap(xstate);
@@ -4102,9 +4102,9 @@ renderPhonebook = function(json, state) {
       }
     ],
     ajax: function(data, callback, settings) {
-      var aa, i, out, ref1, ref2;
+      var i, i1, out, ref1, ref2;
       out = [];
-      for (i = aa = ref1 = data.start, ref2 = data.start + data.length; ref1 <= ref2 ? aa < ref2 : aa > ref2; i = ref1 <= ref2 ? ++aa : --aa) {
+      for (i = i1 = ref1 = data.start, ref2 = data.start + data.length; ref1 <= ref2 ? i1 < ref2 : i1 > ref2; i = ref1 <= ref2 ? ++i1 : --i1) {
         out.push(people[i]);
       }
       return setTimeout(function() {
@@ -4281,7 +4281,7 @@ getSourceType = function(main, t) {
 };
 
 sourcelist = function(json, state) {
-  var aa, ab, act, borked, cl, color, d, dbtn, desc, div, el, firstRun, h, ic, icons, img, item, lastException, lastFailure, lastUpdate, len, len1, len2, len3, lu, m, q, ref, ref1, ref2, ref3, ref4, ref5, retval, running, slist, source, sources, st, status, steps, t, tbody, u, vlist;
+  var act, borked, cl, color, d, dbtn, desc, div, el, firstRun, h, i1, ic, icons, img, item, j1, lastException, lastFailure, lastUpdate, len, len1, len2, len3, lu, m, q, ref, ref1, ref2, ref3, ref4, ref5, retval, running, slist, source, sources, st, status, steps, t, tbody, u, vlist;
   slist = mk('div');
   vlist = new HTML('div');
   if (json.sources) {
@@ -4317,10 +4317,10 @@ sourcelist = function(json, state) {
     }
     sources = sources.sort ? sources : [];
     sources.sort(function(a, b) {
-      return (a.running === b.running ? (a.good === b.good ? (a.sourceURL > b.sourceURL ? 1 : -1) : (b.good === true ? -1 : 1)) : (b.running === true ? 1 : -1));
+      return (a.running === b.running ? (a.good === b.good ? (a.sourceURL > b.sourceURL ? 1 : -1) : (b.good === true ? -1 : 1)) : ((b.running === true) ? 1 : -1));
     });
-    for (aa = 0, len2 = sources.length; aa < len2; aa++) {
-      source = sources[aa];
+    for (i1 = 0, len2 = sources.length; i1 < len2; i1++) {
+      source = sources[i1];
       st = getSourceType(vlist, source.type);
       tbody = st.div;
       st.count++;
@@ -4363,8 +4363,8 @@ sourcelist = function(json, state) {
       if ((ref5 = source.type) === 'irc' || ref5 === 'stats') {
         steps = ['census'];
       }
-      for (ab = 0, len3 = steps.length; ab < len3; ab++) {
-        item = steps[ab];
+      for (j1 = 0, len3 = steps.length; j1 < len3; j1++) {
+        item = steps[j1];
         color = "#394";
         cl = icons[item];
         if (!source.steps || !source.steps[item] || borked) {
@@ -5514,10 +5514,10 @@ comShow = function(t) {
 };
 
 comstat = function(json, state) {
-  var aa, ab, chk, dstyle, hash, i, js, key, lb, len, len1, len2, len3, m, nl, notice, oemail, p, person, q, ref, ref1, ref2, ref3, repo, row, stbl, tb, tbl, tr, u, url, wh, widget;
+  var chk, dstyle, hash, i, i1, j1, js, key, lb, len, len1, len2, len3, m, nl, notice, oemail, p, person, q, ref, ref1, ref2, ref3, repo, row, stbl, tb, tbl, tr, u, url, wh, widget;
   if (json && json.stats) {
     row = new Row();
-    p = new HTML('p', {}, globArgs.committersOnly === 'true' ? "You are currently only seeing stats for committers. To view statistics for all contributors (committers and authors), please uncheck the box below:" : "You are currently seeing stats for both committership and authorship of code. To view only committership stats, tick the box below:");
+    p = new HTML('p', {}, (globArgs.committersOnly === 'true') ? "You are currently only seeing stats for committers. To view statistics for all contributors (committers and authors), please uncheck the box below:" : "You are currently seeing stats for both committership and authorship of code. To view only committership stats, tick the box below:");
     chk = new HTML('input', {
       type: 'checkbox',
       checked: globArgs.committersOnly === 'true' ? 'checked' : null,
@@ -5760,7 +5760,7 @@ comstat = function(json, state) {
         app(tbl, tr);
         tb = new HTML('tbody');
         ref2 = json.stats.converts.issue_to_code;
-        for (i = aa = 0, len2 = ref2.length; aa < len2; i = ++aa) {
+        for (i = i1 = 0, len2 = ref2.length; i1 < len2; i = ++i1) {
           person = ref2[i];
           if (i > 20) {
             break;
@@ -5781,7 +5781,7 @@ comstat = function(json, state) {
               style: {
                 textAlign: 'right'
               }
-            }, (Math.floor(person.tdiff / 86400.)).pretty())
+            }, (Math.floor(person.tdiff / 86400)).pretty())
           ]);
           tb.inject(tr);
         }
@@ -5802,7 +5802,7 @@ comstat = function(json, state) {
         app(tbl, tr);
         tb = new HTML('tbody');
         ref3 = json.stats.converts.email_to_code;
-        for (i = ab = 0, len3 = ref3.length; ab < len3; i = ++ab) {
+        for (i = j1 = 0, len3 = ref3.length; j1 < len3; i = ++j1) {
           person = ref3[i];
           if (i > 20) {
             break;
@@ -5823,7 +5823,7 @@ comstat = function(json, state) {
               style: {
                 textAlign: 'right'
               }
-            }, (Math.floor(person.tdiff / 86400.)).pretty())
+            }, (Math.floor(person.tdiff / 86400)).pretty())
           ]);
           tb.inject(tr);
         }
@@ -5842,7 +5842,7 @@ comstat = function(json, state) {
 };
 
 donut = function(json, state) {
-  var a, aa, blank, chartBox, code, comment, count, data, div, dt, dtl, el, item, l, lang, langs, len, len1, len2, q, ref, top, tot, ttot, u;
+  var a, blank, chartBox, code, comment, count, data, div, dt, dtl, el, i1, item, l, lang, langs, len, len1, len2, q, ref, top, tot, ttot, u;
   dt = [];
   dtl = [];
   l = 0;
@@ -5950,8 +5950,8 @@ donut = function(json, state) {
     theme.color = genColors(17, 0.6, 0.5, true);
   }
   data = {};
-  for (aa = 0, len2 = dt.length; aa < len2; aa++) {
-    el = dt[aa];
+  for (i1 = 0, len2 = dt.length; i1 < len2; i1++) {
+    el = dt[i1];
     data[el.name] = el.value;
   }
   div = new HTML('div');
@@ -6021,7 +6021,7 @@ jsondump = function(json, state) {
 };
 
 linechart = function(json, state) {
-  var aa, ab, cat, catdata, cats, catseries, chartBox, chk, dates, div, filled, from, histograms, id, item, key, label, len, len1, len2, len3, list, m, opt, point, q, range, ref, ref1, ref2, rv, stack, tName, to, type, u, val;
+  var cat, catdata, cats, catseries, chartBox, chk, dates, div, filled, from, histograms, i1, id, item, j1, key, label, len, len1, len2, len3, list, m, opt, point, q, range, ref, ref1, ref2, rv, stack, tName, to, type, u, val;
   div = document.createElement('div');
   if (json.text) {
     div.inject(new HTML('p', {}, json.text));
@@ -6076,8 +6076,8 @@ linechart = function(json, state) {
           catdata[key].push(val);
         }
       }
-      for (aa = 0, len2 = cats.length; aa < len2; aa++) {
-        cat = cats[aa];
+      for (i1 = 0, len2 = cats.length; i1 < len2; i1++) {
+        cat = cats[i1];
         if (ref2 = !cat, indexOf.call(point, ref2) >= 0) {
           catdata[cat].push(0);
         }
@@ -6204,8 +6204,8 @@ linechart = function(json, state) {
     if (state.widget.wargs && state.widget.wargs.histogram === 'hour') {
       histograms.unshift('hour');
     }
-    for (ab = 0, len3 = histograms.length; ab < len3; ab++) {
-      item = histograms[ab];
+    for (j1 = 0, len3 = histograms.length; j1 < len3; j1++) {
+      item = histograms[j1];
       opt = document.createElement('option');
       opt.value = item;
       opt.text = item;
@@ -6330,7 +6330,7 @@ worldmap = function(json, state) {
 };
 
 messages = function(json, state) {
-  var a, aa, ab, b, btn, div, el, form, h2, inp, item, items, len, len1, len2, len3, message, obj, pre, q, ref, ref1, ref2, reply, tbl, tbody, td, thead, tr, u;
+  var a, b, btn, div, el, form, h2, i1, inp, item, items, j1, len, len1, len2, len3, message, obj, pre, q, ref, ref1, ref2, reply, tbl, tbody, td, thead, tr, u;
   if (isArray(json)) {
     obj = document.createElement('form');
     tbl = mk('table');
@@ -6388,8 +6388,8 @@ messages = function(json, state) {
     app(h2, txt("Send a message:"));
     app(obj, h2);
     ref1 = ['recipient', 'subject', 'body'];
-    for (aa = 0, len2 = ref1.length; aa < len2; aa++) {
-      item = ref1[aa];
+    for (i1 = 0, len2 = ref1.length; i1 < len2; i1++) {
+      item = ref1[i1];
       div = mk('div');
       app(div, txt(items[item] + ": "));
       if (item === 'body') {
@@ -6448,8 +6448,8 @@ messages = function(json, state) {
       body: ''
     };
     ref2 = ['recipient', 'subject', 'body'];
-    for (ab = 0, len3 = ref2.length; ab < len3; ab++) {
-      item = ref2[ab];
+    for (j1 = 0, len3 = ref2.length; j1 < len3; j1++) {
+      item = ref2[j1];
       div = mk('div');
       app(div, txt(items[item] + ": "));
       if (item === 'body') {
@@ -6494,7 +6494,7 @@ sendEmail = function(form) {
 };
 
 mvp = function(json, state) {
-  var aa, el, i, len, len1, len2, nlist, person, q, ref, ref1, ref2, tb, tbl, tr, u;
+  var el, i, i1, len, len1, len2, nlist, person, q, ref, ref1, ref2, tb, tbl, tr, u;
   nlist = new HTML('select', {
     name: 'size',
     id: 'size'
@@ -6562,7 +6562,7 @@ mvp = function(json, state) {
   app(tbl, tr);
   tb = new HTML('tbody');
   ref2 = json.sorted;
-  for (i = aa = 0, len2 = ref2.length; aa < len2; i = ++aa) {
+  for (i = i1 = 0, len2 = ref2.length; i1 < len2; i = ++i1) {
     person = ref2[i];
     tr = mk('tr', {
       scope: 'row'
@@ -6897,7 +6897,7 @@ relationship = function(json, state) {
   for (i = q = 1; q <= 5; i = ++q) {
     opt = new HTML('option', {
       value: i,
-      selected: String(i) === globArgs.links ? "selected" : null
+      selected: (String(i) === globArgs.links) ? "selected" : null
     }, String(i));
     sigsel.inject(opt);
   }
@@ -7338,11 +7338,11 @@ treemap = function(json, state) {
         }
       },
       formatter: function(info) {
-        var aa, ref1, treePath, treePathInfo, value;
+        var i1, ref1, treePath, treePathInfo, value;
         value = info.value;
         treePathInfo = info.treePathInfo;
         treePath = [];
-        for (i = aa = 1, ref1 = treePathInfo.length; 1 <= ref1 ? aa < ref1 : aa > ref1; i = 1 <= ref1 ? ++aa : --aa) {
+        for (i = i1 = 1, ref1 = treePathInfo.length; 1 <= ref1 ? i1 < ref1 : i1 > ref1; i = 1 <= ref1 ? ++i1 : --i1) {
           treePath.push(treePathInfo[i].name);
         }
         return ['<div class="tooltip-title">' + treePath.join('/') + '</div>', 'Lines of Code: ' + value.pretty()].join('');
@@ -7542,7 +7542,7 @@ filterView = function(val) {
 };
 
 manageviews = function(json, state) {
-  var aa, btn, h3, h4, inp, len, len1, len2, newdiv, noviews, obj, p, popdiv, q, ref, ref1, ref2, ref3, ref4, sdiv, source, u, view;
+  var btn, h3, h4, i1, inp, len, len1, len2, newdiv, noviews, obj, p, popdiv, q, ref, ref1, ref2, ref3, ref4, sdiv, source, u, view;
   obj = mk('div');
   p = mk('p');
   app(p, txt("Views allow you to quickly set up a group of sources to view as a sub-organisation, much like tags, but faster."));
@@ -7561,7 +7561,7 @@ manageviews = function(json, state) {
   set(newdiv, 'id', 'newdiv');
   newdiv.style.display = "none";
   json.sources.sort(function(a, b) {
-    return (a.type === b.type ? (a.sourceURL > b.sourceURL ? 1 : -1) : (b.type < a.type ? 1 : -1));
+    return (a.type === b.type ? (a.sourceURL > b.sourceURL ? 1 : -1) : ((b.type < a.type) ? 1 : -1));
   });
   inp = mk('input');
   set(inp, 'type', 'text');
@@ -7677,8 +7677,8 @@ manageviews = function(json, state) {
     set(inp, 'id', 'viewname');
     app(newdiv, txt("Select the sources you wish to have in this view below:"));
     ref3 = json.sources;
-    for (aa = 0, len2 = ref3.length; aa < len2; aa++) {
-      source = ref3[aa];
+    for (i1 = 0, len2 = ref3.length; i1 < len2; i1++) {
+      source = ref3[i1];
       sdiv = mk('div');
       set(sdiv, 'id', view.id + "_" + source.sourceID);
       set(sdiv, 'datatype', view.id);