pairing_matrix 1.2 → 2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 62a28ef71e8e75af4ca2fe8f8d83bee4737f55ea
|
4
|
+
data.tar.gz: 552cb865cd768accfee93d7886de6c5045599faa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e6ecaa54d4da86876f90807d0ce33adc23af0f116776a72567d479ad0c590faa5e44d9345fc94c2008241db0ea822d956137893a22764a7ed617858538e38cee
|
7
|
+
data.tar.gz: f366b968892a4759180d082676217f1c6259fa36bad89b55cb61bcb0937694b428b8f7fb1da38171651c685c9c3669c4e679dacd8139559b594e09e3ed485c80
|
data/README.md
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
[](https://badge.fury.io/rb/pairing_matrix)
|
4
4
|

|
5
5
|
[](https://opensource.org/licenses/MIT)
|
6
|
-
[](https://twitter.com/Ajit5ingh)
|
7
7
|
|
8
8
|
<img src="https://github.com/ajitsing/ScreenShots/blob/master/pairing_matrix/pairing_mat.png" width="600" height="550" />
|
9
9
|
|
@@ -2,22 +2,27 @@
|
|
2
2
|
<html lang="en">
|
3
3
|
<head>
|
4
4
|
<title>Pairing Matrix</title>
|
5
|
+
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"/>
|
5
6
|
<link rel="stylesheet" href="style.css"/>
|
6
7
|
<link rel="stylesheet" href="loader.css"/>
|
7
8
|
|
8
9
|
<script language="javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.10.2/jquery.js"></script>
|
9
10
|
<script language="javascript" src="https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js"></script>
|
10
11
|
<script language="javascript" src="https://cdnjs.cloudflare.com/ajax/libs/d3/4.7.3/d3.min.js"></script>
|
12
|
+
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
|
11
13
|
<script language="javascript" src="matrix.js"></script>
|
12
14
|
<script language="javascript" src="index.js"></script>
|
13
15
|
</head>
|
14
16
|
|
15
17
|
<body>
|
16
|
-
<div class="visualize_matrix_container">
|
17
|
-
<
|
18
|
-
<
|
18
|
+
<div class="visualize_matrix_container form-group form-inline">
|
19
|
+
<input type="number" class="form-control" id="days" value="10"/>
|
20
|
+
<button id="visualize" class="btn btn-primary form-control">Visualize</button>
|
21
|
+
</div>
|
22
|
+
<div class="info">
|
23
|
+
<span>Displaying data of last</span>
|
24
|
+
<span id="no_of_days"></span>
|
19
25
|
<span>days</span>
|
20
|
-
<button id="visualize">Visualize</button>
|
21
26
|
</div>
|
22
27
|
|
23
28
|
<div class="loaderContainer">
|
@@ -29,11 +34,22 @@
|
|
29
34
|
</div>
|
30
35
|
</div>
|
31
36
|
|
37
|
+
<span>
|
38
|
+
<div class="authors_container">
|
39
|
+
<div class="buttons btn-group">
|
40
|
+
<button id="reset" class="btn btn-danger">Reset</button>
|
41
|
+
<button id="render" class="btn btn-primary">Visualize</button>
|
42
|
+
</div>
|
43
|
+
<div class="checkbox authors">
|
44
|
+
</div>
|
45
|
+
</div>
|
46
|
+
|
32
47
|
<div class="viz_container">
|
33
48
|
<svg>
|
34
49
|
<g class="area">
|
35
50
|
</g>
|
36
51
|
</svg>
|
37
52
|
</div>
|
53
|
+
</span>
|
38
54
|
</body>
|
39
55
|
</html>
|
@@ -1,10 +1,13 @@
|
|
1
1
|
$(document).ready(function () {
|
2
2
|
var playground = new PlayGround(".area");
|
3
|
+
var pairingData = [];
|
3
4
|
var renderMatrix = function (days) {
|
5
|
+
$('#no_of_days').text(days);
|
4
6
|
hideMatrix();
|
5
7
|
showLoader();
|
6
8
|
$.get('/data/' + days).done(function (data) {
|
7
|
-
|
9
|
+
pairingData = JSON.parse(data);
|
10
|
+
playground.load(pairingData);
|
8
11
|
hideLoader();
|
9
12
|
showMatrix();
|
10
13
|
}).fail(function () {
|
@@ -20,6 +23,22 @@ $(document).ready(function () {
|
|
20
23
|
|
21
24
|
var showMatrix = function () {
|
22
25
|
$('.viz_container').show();
|
26
|
+
var names = [];
|
27
|
+
names = pairingData.map(function(p){ return p[0] });
|
28
|
+
names = names.concat(pairingData.map(function(p){ return p[1] }));
|
29
|
+
names = _.uniq(names).filter(function(n) {return n != ""});
|
30
|
+
|
31
|
+
$('.authors').empty();
|
32
|
+
var sortedNames = names.sort(function (a, b) {
|
33
|
+
if (a > b) return 1;
|
34
|
+
if (b > a) return -1;
|
35
|
+
return 0;
|
36
|
+
});
|
37
|
+
_.each(sortedNames, function (name) {
|
38
|
+
$('.authors').append("<input type='checkbox' checked='true' name='" + name + "'><label for='" + name + "'>" + name + "</label></br>");
|
39
|
+
});
|
40
|
+
|
41
|
+
$(".authors_container").show();
|
23
42
|
};
|
24
43
|
|
25
44
|
var hideLoader = function () {
|
@@ -31,8 +50,30 @@ $(document).ready(function () {
|
|
31
50
|
};
|
32
51
|
|
33
52
|
$('#visualize').on('click', function () {
|
53
|
+
$(".authors_container").hide();
|
34
54
|
renderMatrix($('#days').val())
|
35
55
|
});
|
36
56
|
|
37
57
|
renderMatrix($('#days').val());
|
58
|
+
|
59
|
+
$('#reset').click(function () {
|
60
|
+
_.each($('input[type="checkbox"]'), function (e) {
|
61
|
+
e.checked = false;
|
62
|
+
});
|
63
|
+
});
|
64
|
+
|
65
|
+
$('#render').click(function (e) {
|
66
|
+
var checked = _.filter($('input[type="checkbox"]'), function (e) {
|
67
|
+
return e.checked
|
68
|
+
});
|
69
|
+
var names = _.map(checked, function (checkbox) {
|
70
|
+
return checkbox.name
|
71
|
+
});
|
72
|
+
|
73
|
+
var filteredPairingData = _.filter(pairingData, function (data) {
|
74
|
+
return _.include(names, data[0]) || _.include(names, data[1])
|
75
|
+
});
|
76
|
+
|
77
|
+
playground.load(filteredPairingData);
|
78
|
+
});
|
38
79
|
});
|
@@ -48,6 +48,21 @@ textarea#pairing_text {
|
|
48
48
|
|
49
49
|
.viz_container {
|
50
50
|
text-align: center;
|
51
|
+
float: right;
|
52
|
+
}
|
53
|
+
|
54
|
+
.info {
|
55
|
+
text-align: center;
|
56
|
+
}
|
57
|
+
|
58
|
+
.authors_container {
|
59
|
+
display: none;
|
60
|
+
float: left;
|
61
|
+
}
|
62
|
+
|
63
|
+
.authors {
|
64
|
+
margin-top: 20px;
|
65
|
+
margin-left: 23px;
|
51
66
|
}
|
52
67
|
|
53
68
|
svg {
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pairing_matrix
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '
|
4
|
+
version: '2.0'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ajit Singh
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-07
|
11
|
+
date: 2017-11-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -113,7 +113,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
113
113
|
version: '0'
|
114
114
|
requirements: []
|
115
115
|
rubyforge_project:
|
116
|
-
rubygems_version: 2.6.
|
116
|
+
rubygems_version: 2.6.13
|
117
117
|
signing_key:
|
118
118
|
specification_version: 4
|
119
119
|
summary: Draw pairing matrix from given repos and configurations
|