aa-intel-tool 2.8.0__py3-none-any.whl → 2.9.0__py3-none-any.whl
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.
- aa_intel_tool/__init__.py +1 -1
- aa_intel_tool/static/aa_intel_tool/css/aa-intel-tool.css +5 -0
- aa_intel_tool/static/aa_intel_tool/css/aa-intel-tool.min.css +1 -1
- aa_intel_tool/static/aa_intel_tool/css/aa-intel-tool.min.css.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-chatscan-highlight.js +240 -315
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-chatscan-highlight.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-chatscan-highlight.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-chatscan.js +70 -90
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-chatscan.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-chatscan.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-dscan-highlight.js +58 -90
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-dscan-highlight.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-dscan-highlight.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-dscan.js +158 -197
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-dscan.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-dscan.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-fleetcomposition-highlight.js +79 -93
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-fleetcomposition-highlight.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-fleetcomposition-highlight.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-fleetcomposition.js +67 -91
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-fleetcomposition.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-fleetcomposition.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-scan-result-common.js +322 -132
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-scan-result-common.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool-scan-result-common.min.js.map +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool.js +16 -9
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool.min.js +1 -1
- aa_intel_tool/static/aa_intel_tool/javascript/aa-intel-tool.min.js.map +1 -1
- {aa_intel_tool-2.8.0.dist-info → aa_intel_tool-2.9.0.dist-info}/METADATA +2 -2
- {aa_intel_tool-2.8.0.dist-info → aa_intel_tool-2.9.0.dist-info}/RECORD +32 -32
- {aa_intel_tool-2.8.0.dist-info → aa_intel_tool-2.9.0.dist-info}/WHEEL +0 -0
- {aa_intel_tool-2.8.0.dist-info → aa_intel_tool-2.9.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,140 +1,108 @@
|
|
|
1
1
|
/* jshint -W097 */
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
/* Highlighting similar table rows on mouse over and click for d-scans
|
|
5
|
-
------------------------------------------------------------------------------------- */
|
|
6
|
-
|
|
7
4
|
const elementShipClassTable = $('table.aa-intel-dscan-ship-classes');
|
|
8
5
|
const elementShipTypeTable = $('table.aa-intel-dscan-ship-types');
|
|
9
6
|
|
|
10
|
-
|
|
11
7
|
/**
|
|
12
|
-
* Determine if we can remove all sticky states for this
|
|
8
|
+
* Determine if we can remove all sticky states for this shiptype
|
|
13
9
|
*
|
|
14
10
|
* @param {string} byData The table data attribute for which this function is triggered
|
|
15
|
-
* @param {
|
|
11
|
+
* @param {jQuery|HTMLElement} tableRow The table row that is to be changed
|
|
16
12
|
* @returns {boolean}
|
|
17
13
|
*/
|
|
18
14
|
const removeDscanShiptypeStickyComplete = (byData, tableRow) => {
|
|
19
|
-
|
|
15
|
+
const shiptypeId = tableRow.data('shiptype-id');
|
|
16
|
+
const relatedElements = elementShipClassTable.find(`tr[data-shiptype-id="${shiptypeId}"]`);
|
|
20
17
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
removeSticky = false;
|
|
24
|
-
} else if (byData === 'shipclass' && $(el).hasClass('aa-intel-highlight-sticky')) {
|
|
25
|
-
removeSticky = false;
|
|
26
|
-
}
|
|
27
|
-
});
|
|
18
|
+
return relatedElements.toArray().every((el) => {
|
|
19
|
+
const $el = $(el);
|
|
28
20
|
|
|
29
|
-
|
|
21
|
+
return byData === 'shiptype'
|
|
22
|
+
? $el.hasClass('aa-intel-highlight-sticky') // jshint ignore:line
|
|
23
|
+
: !$el.hasClass('aa-intel-highlight-sticky');
|
|
24
|
+
});
|
|
30
25
|
};
|
|
31
26
|
|
|
32
|
-
|
|
33
27
|
/**
|
|
34
|
-
*
|
|
28
|
+
* Apply or remove CSS class to target elements
|
|
35
29
|
*
|
|
36
30
|
* @param {string} byData The table data attribute for which this function is triggered
|
|
37
|
-
* @param {
|
|
31
|
+
* @param {jQuery|HTMLElement} tableRow The table row that is to be changed
|
|
32
|
+
* @param {string} className The CSS class to add or remove
|
|
33
|
+
* @param {boolean} add Whether to add (true) or remove (false) the class
|
|
38
34
|
*/
|
|
39
|
-
const
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
elementShipTypeTable
|
|
45
|
-
.find(`tr[data-shiptype-id="${tableRow.data('shiptype-id')}"]`)
|
|
46
|
-
.addClass('aa-intel-highlight');
|
|
47
|
-
};
|
|
48
|
-
|
|
35
|
+
const manipulateDscanTableHighlight = ({byData, tableRow, className, add}) => {
|
|
36
|
+
const action = add ? 'addClass' : 'removeClass';
|
|
37
|
+
const shiptypeId = tableRow.data('shiptype-id');
|
|
38
|
+
const dataId = tableRow.data(`${byData}-id`);
|
|
49
39
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
* @param {element} tableRow The table row that is to be changed
|
|
55
|
-
*/
|
|
56
|
-
const removeDscanHighlight = (byData, tableRow) => { // eslint-disable-line no-unused-vars
|
|
57
|
-
elementShipClassTable
|
|
58
|
-
.find(`tr[data-${byData}-id="${tableRow.data(`${byData}-id`)}"]`)
|
|
59
|
-
.removeClass('aa-intel-highlight');
|
|
40
|
+
if (byData === 'shiptype') {
|
|
41
|
+
elementShipClassTable.find(`tr[data-shiptype-id="${shiptypeId}"]`)[action](className);
|
|
42
|
+
} else if (byData === 'shipclass') {
|
|
43
|
+
elementShipClassTable.find(`tr[data-shipclass-id="${dataId}"]`)[action](className);
|
|
60
44
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
45
|
+
if (add || removeDscanShiptypeStickyComplete(byData, tableRow)) {
|
|
46
|
+
elementShipTypeTable.find(`tr[data-shiptype-id="${shiptypeId}"]`)[action](className);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
64
49
|
};
|
|
65
50
|
|
|
66
|
-
|
|
67
51
|
/**
|
|
68
|
-
* Add
|
|
52
|
+
* Add highlight to other tables
|
|
69
53
|
*
|
|
70
54
|
* @param {string} byData The table data attribute for which this function is triggered
|
|
71
|
-
* @param {
|
|
55
|
+
* @param {jQuery|HTMLElement} tableRow The table row that is to be changed
|
|
72
56
|
*/
|
|
73
|
-
const
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
if (byData === 'shipclass') {
|
|
83
|
-
elementShipClassTable
|
|
84
|
-
.find(`tr[data-shipclass-id="${tableRow.data('shipclass-id')}"]`)
|
|
85
|
-
.addClass('aa-intel-highlight-sticky');
|
|
86
|
-
|
|
87
|
-
elementShipTypeTable
|
|
88
|
-
.find(`tr[data-shiptype-id="${tableRow.data('shiptype-id')}"]`)
|
|
89
|
-
.addClass('aa-intel-highlight-sticky');
|
|
90
|
-
}
|
|
57
|
+
const addDscanHighlight = (byData, tableRow) => { // eslint-disable-line no-unused-vars
|
|
58
|
+
manipulateDscanTableHighlight({
|
|
59
|
+
byData: byData,
|
|
60
|
+
tableRow: tableRow,
|
|
61
|
+
className: 'aa-intel-highlight',
|
|
62
|
+
add: true
|
|
63
|
+
});
|
|
91
64
|
};
|
|
92
65
|
|
|
93
|
-
|
|
94
66
|
/**
|
|
95
|
-
* Remove
|
|
67
|
+
* Remove highlight from other tables
|
|
96
68
|
*
|
|
97
69
|
* @param {string} byData The table data attribute for which this function is triggered
|
|
98
|
-
* @param {
|
|
70
|
+
* @param {jQuery|HTMLElement} tableRow The table row that is to be changed
|
|
99
71
|
*/
|
|
100
|
-
const
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
if (byData === 'shipclass') {
|
|
110
|
-
elementShipClassTable
|
|
111
|
-
.find(`tr[data-shipclass-id="${tableRow.data('shipclass-id')}"]`)
|
|
112
|
-
.removeClass('aa-intel-highlight-sticky');
|
|
113
|
-
|
|
114
|
-
if (removeDscanShiptypeStickyComplete(byData, tableRow) === true) {
|
|
115
|
-
elementShipTypeTable
|
|
116
|
-
.find(`tr[data-shiptype-id="${tableRow.data('shiptype-id')}"]`)
|
|
117
|
-
.removeClass('aa-intel-highlight-sticky');
|
|
118
|
-
}
|
|
119
|
-
}
|
|
72
|
+
const removeDscanHighlight = (byData, tableRow) => { // eslint-disable-line no-unused-vars
|
|
73
|
+
manipulateDscanTableHighlight({
|
|
74
|
+
byData: byData,
|
|
75
|
+
tableRow: tableRow,
|
|
76
|
+
className: 'aa-intel-highlight',
|
|
77
|
+
add: false
|
|
78
|
+
});
|
|
120
79
|
};
|
|
121
80
|
|
|
122
|
-
|
|
123
81
|
/**
|
|
124
82
|
* Change the status of the sticky highlight
|
|
125
83
|
*
|
|
126
84
|
* @param {string} byData The table data attribute for which this function is triggered
|
|
127
|
-
* @param {
|
|
85
|
+
* @param {jQuery|HTMLElement} tableRow The table row that is to be changed
|
|
128
86
|
*/
|
|
129
87
|
const changeDscanStickyHighlight = (byData, tableRow) => { // eslint-disable-line no-unused-vars
|
|
130
88
|
if (
|
|
131
89
|
(
|
|
132
90
|
byData === 'shiptype' && tableRow.hasClass('aa-intel-highlight-sticky') === true
|
|
133
|
-
&& removeDscanShiptypeStickyComplete(byData, tableRow) === true
|
|
91
|
+
&& removeDscanShiptypeStickyComplete(byData, tableRow) === true // jshint ignore:line
|
|
134
92
|
) || (byData === 'shipclass' && tableRow.hasClass('aa-intel-highlight-sticky') === true)
|
|
135
93
|
) {
|
|
136
|
-
|
|
94
|
+
manipulateDscanTableHighlight({
|
|
95
|
+
byData: byData,
|
|
96
|
+
tableRow: tableRow,
|
|
97
|
+
className: 'aa-intel-highlight-sticky',
|
|
98
|
+
add: false
|
|
99
|
+
});
|
|
137
100
|
} else {
|
|
138
|
-
|
|
101
|
+
manipulateDscanTableHighlight({
|
|
102
|
+
byData: byData,
|
|
103
|
+
tableRow: tableRow,
|
|
104
|
+
className: 'aa-intel-highlight-sticky',
|
|
105
|
+
add: true
|
|
106
|
+
});
|
|
139
107
|
}
|
|
140
108
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const elementShipClassTable=$(
|
|
1
|
+
'use strict';const elementShipClassTable=$('table.aa-intel-dscan-ship-classes'),elementShipTypeTable=$('table.aa-intel-dscan-ship-types'),removeDscanShiptypeStickyComplete=(a,t)=>{const e=t.data('shiptype-id');return elementShipClassTable.find(`tr[data-shiptype-id="${e}"]`).toArray().every(t=>{const e=$(t);return'shiptype'===a?e.hasClass('aa-intel-highlight-sticky'):!e.hasClass('aa-intel-highlight-sticky')})},manipulateDscanTableHighlight=({byData:a,tableRow:t,className:e,add:i})=>{const s=i?'addClass':'removeClass',l=t.data('shiptype-id'),h=t.data(`${a}-id`);'shiptype'===a?elementShipClassTable.find(`tr[data-shiptype-id="${l}"]`)[s](e):'shipclass'===a&&(elementShipClassTable.find(`tr[data-shipclass-id="${h}"]`)[s](e),(i||removeDscanShiptypeStickyComplete(a,t))&&elementShipTypeTable.find(`tr[data-shiptype-id="${l}"]`)[s](e))},addDscanHighlight=(a,t)=>{manipulateDscanTableHighlight({byData:a,tableRow:t,className:'aa-intel-highlight',add:!0})},removeDscanHighlight=(a,t)=>{manipulateDscanTableHighlight({byData:a,tableRow:t,className:'aa-intel-highlight',add:!1})},changeDscanStickyHighlight=(a,t)=>{'shiptype'===a&&!0===t.hasClass('aa-intel-highlight-sticky')&&!0===removeDscanShiptypeStickyComplete(a,t)||'shipclass'===a&&!0===t.hasClass('aa-intel-highlight-sticky')?manipulateDscanTableHighlight({byData:a,tableRow:t,className:'aa-intel-highlight-sticky',add:!1}):manipulateDscanTableHighlight({byData:a,tableRow:t,className:'aa-intel-highlight-sticky',add:!0})};
|
|
2
2
|
//# sourceMappingURL=aa-intel-tool-dscan-highlight.min.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"names":["elementShipClassTable","$","elementShipTypeTable","removeDscanShiptypeStickyComplete","byData","tableRow","shiptypeId","data","find","toArray","every","el","$el","hasClass","manipulateDscanTableHighlight","className","add","action","dataId","addDscanHighlight","removeDscanHighlight","changeDscanStickyHighlight"],"sources":["aa-intel-tool-dscan-highlight.js"],"mappings":"AACA,aAEA,MAAMA,sBAAwBC,EAAE,qCAC1BC,qBAAuBD,EAAE,mCASzBE,kCAAoC,CAACC,EAAQC,KAC/C,MAAMC,EAAaD,EAASE,KAAK,eAGjC,OAFwBP,sBAAsBQ,KAAK,wBAAwBF,OAEpDG,UAAUC,MAAOC,IACpC,MAAMC,EAAMX,EAAEU,GAEd,MAAkB,aAAXP,EACDQ,EAAIC,SAAS,8BACZD,EAAIC,SAAS,gCAYtBC,8BAAgC,EAAEV,SAAQC,WAAUU,YAAWC,UACjE,MAAMC,EAASD,EAAM,WAAa,cAC5BV,EAAaD,EAASE,KAAK,eAC3BW,EAASb,EAASE,KAAK,GAAGH,QAEjB,aAAXA,EACAJ,sBAAsBQ,KAAK,wBAAwBF,OAAgBW,GAAQF,GACzD,cAAXX,IACPJ,sBAAsBQ,KAAK,yBAAyBU,OAAYD,GAAQF,IAEpEC,GAAOb,kCAAkCC,EAAQC,KACjDH,qBAAqBM,KAAK,wBAAwBF,OAAgBW,GAAQF,KAWhFI,kBAAoB,CAACf,EAAQC,KAC/BS,8BAA8B,CAC1BV,OAAQA,EACRC,SAAUA,EACVU,UAAW,qBACXC,KAAK,KAUPI,qBAAuB,CAAChB,EAAQC,KAClCS,8BAA8B,CAC1BV,OAAQA,EACRC,SAAUA,EACVU,UAAW,qBACXC,KAAK,KAUPK,2BAA6B,CAACjB,EAAQC,KAGrB,aAAXD,IAA4E,IAAnDC,EAASQ,SAAS,+BACgB,IAAxDV,kCAAkCC,EAAQC,IAChC,cAAXD,IAA6E,IAAnDC,EAASQ,SAAS,6BAElDC,8BAA8B,CAC1BV,OAAQA,EACRC,SAAUA,EACVU,UAAW,4BACXC,KAAK,IAGTF,8BAA8B,CAC1BV,OAAQA,EACRC,SAAUA,EACVU,UAAW,4BACXC,KAAK","ignoreList":[]}
|