forked from vern/website
Change const to 1000 and do some re-styling
Signed-off-by: Skylar "The Cobra" Widulski <cobra@vern.cc>
This commit is contained in:
parent
738c6ce41e
commit
efb1bf180a
|
@ -16,7 +16,7 @@
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<?php
|
<?php
|
||||||
$const = 300;
|
$const = 1000;
|
||||||
$langs = array();
|
$langs = array();
|
||||||
$langs['pt-BR'] = array("Brazilian Portuguese", "Português Brasileiro");
|
$langs['pt-BR'] = array("Brazilian Portuguese", "Português Brasileiro");
|
||||||
|
|
||||||
|
@ -25,7 +25,8 @@
|
||||||
global $langs;
|
global $langs;
|
||||||
|
|
||||||
$sum = shell_exec('cd /var/www/website; echo "$(($(diff 2>/dev/null -y --suppress-common-lines en/ '.$tl.'/ | grep "|" | wc -l)+$(diff 2>/dev/null -y --suppress-common-lines en/ '.$tl.'/ | grep "^Only in en/" | awk '."'".'{print $NF}'."'".' | while read -r line; do wc -l < en/"$line";printf "+"; done)0))"');
|
$sum = shell_exec('cd /var/www/website; echo "$(($(diff 2>/dev/null -y --suppress-common-lines en/ '.$tl.'/ | grep "|" | wc -l)+$(diff 2>/dev/null -y --suppress-common-lines en/ '.$tl.'/ | grep "^Only in en/" | awk '."'".'{print $NF}'."'".' | while read -r line; do wc -l < en/"$line";printf "+"; done)0))"');
|
||||||
return "<li>" . $langs[$tl][0] . " (" . $langs[$tl][1] . ", <code>/" . $tl . "/</code>)" . "</li>\n<br>\n<progress max=$const value=" . $sum . ">" . intdiv(($sum * 100), $const) . "%</progress><br><br>";
|
$percent = intdiv(($sum * 100), $const);
|
||||||
|
return "<li>" . $langs[$tl][0] . " (" . $langs[$tl][1] . ", <code>/$tl/</code>)</li>\n<p>$percent</p>\n<progress max=$const value=$sum>$percent%</progress><br>";
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<!--#include file="nav.php" -->
|
<!--#include file="nav.php" -->
|
||||||
|
|
|
@ -76,9 +76,9 @@ input[type=submit] {
|
||||||
}
|
}
|
||||||
|
|
||||||
progress {
|
progress {
|
||||||
height: 30px;
|
height: 20px;
|
||||||
width: 70%;
|
width: 70%;
|
||||||
border-radius: 15px;
|
border-radius: 10px;
|
||||||
border: 1px solid transparent;
|
border: 1px solid transparent;
|
||||||
background: #bbc2cf;
|
background: #bbc2cf;
|
||||||
color: #ff6c6b;
|
color: #ff6c6b;
|
||||||
|
@ -86,7 +86,7 @@ progress {
|
||||||
|
|
||||||
progress::-moz-progress-bar {
|
progress::-moz-progress-bar {
|
||||||
color: transparent;
|
color: transparent;
|
||||||
background: #bbc2cf;
|
background: currentColor;
|
||||||
accent-color: currentColor;
|
accent-color: currentColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue