Integrate RelaySearch (Fixes: #25392)
This is using commit b6e6c3235806c9d1521dbc2c08cecee626466928 of atlas.git. * Removes submodule for RS. * Move two license files to basedirectory; these should be merged. * Move atlas.css into css folder * Fonts in both were identical * Changes all findable paths to the new setting * js libs were simply copied; these should be sorted out more * Merged rs/img and rs/images folder into images Thanks to iwakeh for the bulk of the work in this commit.
5
.gitignore
vendored
@ -21,3 +21,8 @@ legacy.config
|
||||
# other
|
||||
*~
|
||||
|
||||
# Ignore git mergetool backup files
|
||||
*.orig
|
||||
|
||||
# Ignore Vim swap files
|
||||
*.swp
|
||||
|
3
.gitmodules
vendored
@ -4,6 +4,3 @@
|
||||
[submodule "src/submods/metrics-lib"]
|
||||
path = src/submods/metrics-lib
|
||||
url = https://git.torproject.org/metrics-lib.git
|
||||
[submodule "src/main/resources/web/rs"]
|
||||
path = src/main/resources/web/rs
|
||||
url = https://git.torproject.org/atlas.git
|
||||
|
35
LICENCE.flags
Normal file
@ -0,0 +1,35 @@
|
||||
These flags are built from the sources at:
|
||||
|
||||
https://github.com/gosquared/flags
|
||||
|
||||
To update these flags:
|
||||
|
||||
* apt install pngcrush imagemagick icnsutils rename
|
||||
* git clone https://github.com/gosquared/flags
|
||||
* cd flags; make
|
||||
* cp flags/flags-iso/shiny/16/* $RELAYSEARCH/img/cc/
|
||||
* cd $RELAYSEARCH/img/cc/; rename 'y/A-Z/a-z/' *.png; cp _unknown.png xz.png
|
||||
|
||||
The flags are made available under the MIT license:
|
||||
|
||||
-----------------------------------------------------------------------
|
||||
Copyright (c) 2017 Go Squared Ltd. http://www.gosquared.com/
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is furnished to do
|
||||
so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
-----------------------------------------------------------------------
|
23
LICENSE.relaysearch
Normal file
@ -0,0 +1,23 @@
|
||||
Copyright (c) 2012, 2013, Arturo Filastò
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright notice, this
|
||||
list of conditions and the following disclaimer.
|
||||
|
||||
2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
this list of conditions and the following disclaimer in the documentation
|
||||
and/or other materials provided with the distribution.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
||||
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
@ -182,7 +182,7 @@
|
||||
includes="logback.xml" />
|
||||
<zipfileset dir="${resources}/web"
|
||||
prefix=""
|
||||
includes="css/* images/* js/* fonts/** rs/**" />
|
||||
includes="css/* images/** js/** fonts/** templates/**" />
|
||||
<zipfileset dir="${resources}/web/jsps"
|
||||
prefix="WEB-INF"
|
||||
includes="*.jsp"/>
|
||||
|
@ -23,7 +23,7 @@ public class RelaySearchServlet extends AnyServlet {
|
||||
HttpServletResponse response) throws IOException, ServletException {
|
||||
|
||||
/* Forward the request to the JSP that does all the hard work. */
|
||||
String[] additionalStylesheets = {"/rs/css/atlas.css"};
|
||||
String[] additionalStylesheets = {"/css/atlas.css"};
|
||||
request.setAttribute("additionalStylesheets", additionalStylesheets);
|
||||
request.setAttribute("categories", this.categories);
|
||||
request.getRequestDispatcher("WEB-INF/rs.jsp").forward(request,
|
||||
|
103
src/main/resources/web/css/atlas.css
Normal file
@ -0,0 +1,103 @@
|
||||
.progress {
|
||||
width: 50%;
|
||||
margin: 100px auto;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.progress-bar {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#secondary-search {
|
||||
display: none;
|
||||
}
|
||||
|
||||
a.alleged {
|
||||
color: #FE9F30;
|
||||
}
|
||||
|
||||
.flags {
|
||||
padding: 2px;
|
||||
}
|
||||
|
||||
span.flags {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.tooltip-inner {
|
||||
text-align:left;
|
||||
}
|
||||
|
||||
#outdatedData > div {
|
||||
position:relative;
|
||||
top:60px;
|
||||
}
|
||||
|
||||
.circle {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
background: #999999;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
-moz-border-radius: 50%;
|
||||
-webkit-border-radius: 50%;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.circle-online {
|
||||
background: #25d918;
|
||||
}
|
||||
|
||||
.circle-offline {
|
||||
background: #ff1515;
|
||||
}
|
||||
|
||||
#home-search, #home-aggregate-search, #home-advanced-search, #map-radio-buttons {
|
||||
padding: 0;
|
||||
margin: 0 0 10px 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
td, th {
|
||||
padding: 2px!important;
|
||||
}
|
||||
|
||||
.form-control {
|
||||
max-width: none !important;
|
||||
}
|
||||
|
||||
.flags-cell {
|
||||
width: 150px;
|
||||
}
|
||||
|
||||
/* Allow displaying long contact info (#23868) */
|
||||
dd {
|
||||
-ms-word-break: break-all;
|
||||
word-break: break-all;
|
||||
|
||||
/* Non standard for webkit */
|
||||
word-break: break-word;
|
||||
|
||||
-webkit-hyphens: auto;
|
||||
-moz-hyphens: auto;
|
||||
hyphens: auto;
|
||||
}
|
||||
|
||||
/* Override style.css from metrics.torproject.org style */
|
||||
td a {
|
||||
padding-right: 0 !important;
|
||||
}
|
||||
|
||||
.day-spinner {
|
||||
width: 120px;
|
||||
display: inline;
|
||||
}
|
||||
|
||||
label.radio-inline {
|
||||
display: inline !important;
|
||||
width: auto;
|
||||
}
|
||||
|
||||
#no-svg {
|
||||
display: none;
|
||||
}
|
BIN
src/main/resources/web/images/atlas.png
Normal file
After Width: | Height: | Size: 3.2 KiB |
BIN
src/main/resources/web/images/atlas.xcf
Normal file
BIN
src/main/resources/web/images/cc/_abkhazia.png
Normal file
After Width: | Height: | Size: 442 B |
BIN
src/main/resources/web/images/cc/_basque-country.png
Normal file
After Width: | Height: | Size: 445 B |
After Width: | Height: | Size: 493 B |
BIN
src/main/resources/web/images/cc/_commonwealth.png
Normal file
After Width: | Height: | Size: 587 B |
BIN
src/main/resources/web/images/cc/_england.png
Normal file
After Width: | Height: | Size: 327 B |
BIN
src/main/resources/web/images/cc/_gosquared.png
Normal file
After Width: | Height: | Size: 444 B |
BIN
src/main/resources/web/images/cc/_kosovo.png
Normal file
After Width: | Height: | Size: 560 B |
BIN
src/main/resources/web/images/cc/_mars.png
Normal file
After Width: | Height: | Size: 417 B |
BIN
src/main/resources/web/images/cc/_nagorno-karabakh.png
Normal file
After Width: | Height: | Size: 355 B |
BIN
src/main/resources/web/images/cc/_nato.png
Normal file
After Width: | Height: | Size: 353 B |
BIN
src/main/resources/web/images/cc/_northern-cyprus.png
Normal file
After Width: | Height: | Size: 407 B |
BIN
src/main/resources/web/images/cc/_olympics.png
Normal file
After Width: | Height: | Size: 469 B |
BIN
src/main/resources/web/images/cc/_red-cross.png
Normal file
After Width: | Height: | Size: 315 B |
BIN
src/main/resources/web/images/cc/_scotland.png
Normal file
After Width: | Height: | Size: 472 B |
BIN
src/main/resources/web/images/cc/_somaliland.png
Normal file
After Width: | Height: | Size: 441 B |
BIN
src/main/resources/web/images/cc/_south-ossetia.png
Normal file
After Width: | Height: | Size: 287 B |
BIN
src/main/resources/web/images/cc/_united-nations.png
Normal file
After Width: | Height: | Size: 507 B |
BIN
src/main/resources/web/images/cc/_unknown.png
Normal file
After Width: | Height: | Size: 393 B |
BIN
src/main/resources/web/images/cc/_wales.png
Normal file
After Width: | Height: | Size: 577 B |
BIN
src/main/resources/web/images/cc/ad.png
Normal file
After Width: | Height: | Size: 528 B |
BIN
src/main/resources/web/images/cc/ae.png
Normal file
After Width: | Height: | Size: 386 B |
BIN
src/main/resources/web/images/cc/af.png
Normal file
After Width: | Height: | Size: 528 B |
BIN
src/main/resources/web/images/cc/ag.png
Normal file
After Width: | Height: | Size: 410 B |
BIN
src/main/resources/web/images/cc/ai.png
Normal file
After Width: | Height: | Size: 502 B |
BIN
src/main/resources/web/images/cc/al.png
Normal file
After Width: | Height: | Size: 467 B |
BIN
src/main/resources/web/images/cc/am.png
Normal file
After Width: | Height: | Size: 293 B |
BIN
src/main/resources/web/images/cc/an.png
Normal file
After Width: | Height: | Size: 361 B |
BIN
src/main/resources/web/images/cc/ao.png
Normal file
After Width: | Height: | Size: 416 B |
BIN
src/main/resources/web/images/cc/aq.png
Normal file
After Width: | Height: | Size: 516 B |
BIN
src/main/resources/web/images/cc/ar.png
Normal file
After Width: | Height: | Size: 389 B |
BIN
src/main/resources/web/images/cc/as.png
Normal file
After Width: | Height: | Size: 560 B |
BIN
src/main/resources/web/images/cc/at.png
Normal file
After Width: | Height: | Size: 295 B |
BIN
src/main/resources/web/images/cc/au.png
Normal file
After Width: | Height: | Size: 442 B |
BIN
src/main/resources/web/images/cc/aw.png
Normal file
After Width: | Height: | Size: 368 B |
BIN
src/main/resources/web/images/cc/ax.png
Normal file
After Width: | Height: | Size: 362 B |
BIN
src/main/resources/web/images/cc/az.png
Normal file
After Width: | Height: | Size: 437 B |
BIN
src/main/resources/web/images/cc/ba.png
Normal file
After Width: | Height: | Size: 520 B |
BIN
src/main/resources/web/images/cc/bb.png
Normal file
After Width: | Height: | Size: 379 B |
BIN
src/main/resources/web/images/cc/bd.png
Normal file
After Width: | Height: | Size: 420 B |
BIN
src/main/resources/web/images/cc/be.png
Normal file
After Width: | Height: | Size: 413 B |
BIN
src/main/resources/web/images/cc/bf.png
Normal file
After Width: | Height: | Size: 343 B |
BIN
src/main/resources/web/images/cc/bg.png
Normal file
After Width: | Height: | Size: 287 B |
BIN
src/main/resources/web/images/cc/bh.png
Normal file
After Width: | Height: | Size: 449 B |
BIN
src/main/resources/web/images/cc/bi.png
Normal file
After Width: | Height: | Size: 552 B |
BIN
src/main/resources/web/images/cc/bj.png
Normal file
After Width: | Height: | Size: 387 B |
BIN
src/main/resources/web/images/cc/bl.png
Normal file
After Width: | Height: | Size: 578 B |
BIN
src/main/resources/web/images/cc/bm.png
Normal file
After Width: | Height: | Size: 491 B |
BIN
src/main/resources/web/images/cc/bn.png
Normal file
After Width: | Height: | Size: 581 B |
BIN
src/main/resources/web/images/cc/bo.png
Normal file
After Width: | Height: | Size: 418 B |
BIN
src/main/resources/web/images/cc/br.png
Normal file
After Width: | Height: | Size: 529 B |
BIN
src/main/resources/web/images/cc/bs.png
Normal file
After Width: | Height: | Size: 435 B |
BIN
src/main/resources/web/images/cc/bt.png
Normal file
After Width: | Height: | Size: 581 B |
BIN
src/main/resources/web/images/cc/bv.png
Normal file
After Width: | Height: | Size: 512 B |
BIN
src/main/resources/web/images/cc/bw.png
Normal file
After Width: | Height: | Size: 292 B |
BIN
src/main/resources/web/images/cc/by.png
Normal file
After Width: | Height: | Size: 436 B |
BIN
src/main/resources/web/images/cc/bz.png
Normal file
After Width: | Height: | Size: 473 B |
BIN
src/main/resources/web/images/cc/ca.png
Normal file
After Width: | Height: | Size: 389 B |
BIN
src/main/resources/web/images/cc/cc.png
Normal file
After Width: | Height: | Size: 462 B |
BIN
src/main/resources/web/images/cc/cd.png
Normal file
After Width: | Height: | Size: 573 B |
BIN
src/main/resources/web/images/cc/cf.png
Normal file
After Width: | Height: | Size: 358 B |
BIN
src/main/resources/web/images/cc/cg.png
Normal file
After Width: | Height: | Size: 471 B |
BIN
src/main/resources/web/images/cc/ch.png
Normal file
After Width: | Height: | Size: 335 B |
BIN
src/main/resources/web/images/cc/ci.png
Normal file
After Width: | Height: | Size: 421 B |
BIN
src/main/resources/web/images/cc/ck.png
Normal file
After Width: | Height: | Size: 516 B |
BIN
src/main/resources/web/images/cc/cl.png
Normal file
After Width: | Height: | Size: 367 B |
BIN
src/main/resources/web/images/cc/cm.png
Normal file
After Width: | Height: | Size: 464 B |
BIN
src/main/resources/web/images/cc/cn.png
Normal file
After Width: | Height: | Size: 506 B |
BIN
src/main/resources/web/images/cc/co.png
Normal file
After Width: | Height: | Size: 293 B |
BIN
src/main/resources/web/images/cc/cr.png
Normal file
After Width: | Height: | Size: 289 B |
BIN
src/main/resources/web/images/cc/cs.png
Normal file
After Width: | Height: | Size: 439 B |
BIN
src/main/resources/web/images/cc/ct.png
Normal file
After Width: | Height: | Size: 403 B |
BIN
src/main/resources/web/images/cc/cu.png
Normal file
After Width: | Height: | Size: 457 B |
BIN
src/main/resources/web/images/cc/cv.png
Normal file
After Width: | Height: | Size: 333 B |
BIN
src/main/resources/web/images/cc/cw.png
Normal file
After Width: | Height: | Size: 379 B |
BIN
src/main/resources/web/images/cc/cx.png
Normal file
After Width: | Height: | Size: 542 B |
BIN
src/main/resources/web/images/cc/cy.png
Normal file
After Width: | Height: | Size: 499 B |
BIN
src/main/resources/web/images/cc/cz.png
Normal file
After Width: | Height: | Size: 432 B |
BIN
src/main/resources/web/images/cc/de.png
Normal file
After Width: | Height: | Size: 295 B |
BIN
src/main/resources/web/images/cc/dj.png
Normal file
After Width: | Height: | Size: 440 B |
BIN
src/main/resources/web/images/cc/dk.png
Normal file
After Width: | Height: | Size: 326 B |
BIN
src/main/resources/web/images/cc/dm.png
Normal file
After Width: | Height: | Size: 504 B |
BIN
src/main/resources/web/images/cc/do.png
Normal file
After Width: | Height: | Size: 411 B |
BIN
src/main/resources/web/images/cc/dz.png
Normal file
After Width: | Height: | Size: 565 B |
BIN
src/main/resources/web/images/cc/ec.png
Normal file
After Width: | Height: | Size: 421 B |
BIN
src/main/resources/web/images/cc/ee.png
Normal file
After Width: | Height: | Size: 293 B |
BIN
src/main/resources/web/images/cc/eg.png
Normal file
After Width: | Height: | Size: 374 B |
BIN
src/main/resources/web/images/cc/eh.png
Normal file
After Width: | Height: | Size: 473 B |
BIN
src/main/resources/web/images/cc/er.png
Normal file
After Width: | Height: | Size: 552 B |
BIN
src/main/resources/web/images/cc/es.png
Normal file
After Width: | Height: | Size: 417 B |
BIN
src/main/resources/web/images/cc/et.png
Normal file
After Width: | Height: | Size: 495 B |
BIN
src/main/resources/web/images/cc/eu.png
Normal file
After Width: | Height: | Size: 530 B |