mirror of
https://github.com/lrsjng/h5ai.git
synced 2025-05-25 12:34:47 -04:00
Update info page.
This commit is contained in:
parent
aa5c110448
commit
ca816a5745
6 changed files with 80 additions and 164 deletions
|
@ -1,77 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
id="svg7384"
|
|
||||||
height="16"
|
|
||||||
width="16"
|
|
||||||
version="1.1"
|
|
||||||
inkscape:version="0.48.4 r9939"
|
|
||||||
sodipodi:docname="app.svg"
|
|
||||||
inkscape:export-filename="/home/lars/env/workspace/h5ai/src/_h5ai/client/images/favicon/app-32.png"
|
|
||||||
inkscape:export-xdpi="180"
|
|
||||||
inkscape:export-ydpi="180">
|
|
||||||
<defs
|
|
||||||
id="defs10" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1"
|
|
||||||
objecttolerance="10"
|
|
||||||
gridtolerance="10"
|
|
||||||
guidetolerance="10"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:window-width="1877"
|
|
||||||
inkscape:window-height="1056"
|
|
||||||
id="namedview8"
|
|
||||||
showgrid="true"
|
|
||||||
inkscape:zoom="41.7193"
|
|
||||||
inkscape:cx="10.567799"
|
|
||||||
inkscape:cy="6.7528912"
|
|
||||||
inkscape:window-x="43"
|
|
||||||
inkscape:window-y="24"
|
|
||||||
inkscape:window-maximized="1"
|
|
||||||
inkscape:current-layer="svg7384"
|
|
||||||
showguides="true"
|
|
||||||
inkscape:guide-bbox="true">
|
|
||||||
<sodipodi:guide
|
|
||||||
orientation="-0.70710678,0.70710678"
|
|
||||||
position="-13.926408,17.473927"
|
|
||||||
id="guide2996" />
|
|
||||||
<inkscape:grid
|
|
||||||
type="xygrid"
|
|
||||||
id="grid3002"
|
|
||||||
empspacing="5"
|
|
||||||
visible="true"
|
|
||||||
enabled="true"
|
|
||||||
snapvisiblegridlinesonly="true" />
|
|
||||||
</sodipodi:namedview>
|
|
||||||
<metadata
|
|
||||||
id="metadata90">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title>Gnome Symbolic Icon Theme</dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<title
|
|
||||||
id="title9167">Gnome Symbolic Icon Theme</title>
|
|
||||||
<path
|
|
||||||
style="fill:#555555"
|
|
||||||
d="M 0,3 0,15 16,15 16,3 11,3 9,1 2,1 z"
|
|
||||||
id="rect3845"
|
|
||||||
inkscape:connector-curvature="0"
|
|
||||||
sodipodi:nodetypes="cccccccc" />
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 2.2 KiB |
Before Width: | Height: | Size: 800 B After Width: | Height: | Size: 800 B |
Before Width: | Height: | Size: 5.3 KiB After Width: | Height: | Size: 5.3 KiB |
|
@ -1,44 +1,90 @@
|
||||||
|
|
||||||
modulejs.define('info', ['$', 'config'], function ($, config) {
|
modulejs.define('info', ['$', 'config'], function ($, config) {
|
||||||
|
|
||||||
var map = function (setup) {
|
var template = '<li class="test">' +
|
||||||
|
'<span class="label"></span>' +
|
||||||
|
'<span class="result"></span>' +
|
||||||
|
'<div class="info"></div>' +
|
||||||
|
'</li>',
|
||||||
|
|
||||||
return {
|
$tests = $('#tests'),
|
||||||
'php_version': setup.HAS_PHP_VERSION,
|
|
||||||
'cache_dir': setup.HAS_WRITABLE_CACHE,
|
|
||||||
'image_thumbs': setup.HAS_PHP_JPG,
|
|
||||||
'exif_thumbs': setup.HAS_PHP_EXIF,
|
|
||||||
'movie_thumbs': setup.HAS_CMD_FFMPEG || setup.HAS_CMD_AVCONV,
|
|
||||||
'pdf_thumbs': setup.HAS_CMD_CONVERT,
|
|
||||||
'shell_tar': setup.HAS_CMD_TAR,
|
|
||||||
'shell_zip': setup.HAS_CMD_ZIP,
|
|
||||||
'folder_sizes': setup.HAS_CMD_DU
|
|
||||||
};
|
|
||||||
},
|
|
||||||
|
|
||||||
setValue = function (el, result) {
|
addTestResult = function (label, info, passed, result) {
|
||||||
|
|
||||||
var $result = $(el).find('.result');
|
$(template)
|
||||||
|
.find('.label')
|
||||||
if (result) {
|
.text(label)
|
||||||
$result.addClass('passed').text('yes');
|
.end()
|
||||||
} else {
|
.find('.result')
|
||||||
$result.addClass('failed').text('no');
|
.addClass(passed ? 'passed' : 'failed')
|
||||||
}
|
.text(result ? result : (passed ? 'yes' : 'no'))
|
||||||
|
.end()
|
||||||
|
.find('.info')
|
||||||
|
.html(info)
|
||||||
|
.end()
|
||||||
|
.appendTo($tests);
|
||||||
},
|
},
|
||||||
|
|
||||||
init = function () {
|
init = function () {
|
||||||
|
|
||||||
var setup = config.setup,
|
var setup = config.setup;
|
||||||
values = map(setup);
|
|
||||||
|
|
||||||
$('.test').each(function () {
|
|
||||||
|
|
||||||
setValue(this, values[$(this).data('id')]);
|
|
||||||
});
|
|
||||||
|
|
||||||
$('.idx-file .value').text(setup.INDEX_HREF);
|
$('.idx-file .value').text(setup.INDEX_HREF);
|
||||||
$('.test.php .result').text(setup.PHP_VERSION);
|
|
||||||
|
addTestResult(
|
||||||
|
'PHP version',
|
||||||
|
'PHP version >= 5.3.0',
|
||||||
|
setup.HAS_PHP_VERSION,
|
||||||
|
setup.PHP_VERSION
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Cache directory',
|
||||||
|
'Web server has write access',
|
||||||
|
setup.HAS_WRITABLE_CACHE
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Image thumbs',
|
||||||
|
'PHP GD extension with JPEG support available',
|
||||||
|
setup.HAS_PHP_JPG
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Use EXIF thumbs',
|
||||||
|
'PHP EXIF extension available',
|
||||||
|
setup.HAS_PHP_EXIF
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Movie thumbs',
|
||||||
|
'Command line program <code>ffmpeg</code> or <code>avconv</code> available',
|
||||||
|
setup.HAS_CMD_FFMPEG || setup.HAS_CMD_AVCONV
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'PDF thumbs',
|
||||||
|
'Command line program <code>convert</code> available',
|
||||||
|
setup.HAS_CMD_CONVERT
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Shell tar',
|
||||||
|
'Command line program <code>tar</code> available',
|
||||||
|
setup.HAS_CMD_TAR
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Shell zip',
|
||||||
|
'Command line program <code>zip</code> available',
|
||||||
|
setup.HAS_CMD_ZIP
|
||||||
|
);
|
||||||
|
|
||||||
|
addTestResult(
|
||||||
|
'Folder sizes',
|
||||||
|
'Command line program <code>du</code> available',
|
||||||
|
setup.HAS_CMD_DU
|
||||||
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
init();
|
init();
|
||||||
|
|
|
@ -9,10 +9,10 @@ html.no-js.browser( lang="en" )
|
||||||
meta( charset="utf-8" )
|
meta( charset="utf-8" )
|
||||||
meta( http-equiv="X-UA-Compatible", content="IE=edge" )
|
meta( http-equiv="X-UA-Compatible", content="IE=edge" )
|
||||||
title {{pkg.name}} {{pkg.version}} Server Setup
|
title {{pkg.name}} {{pkg.version}} Server Setup
|
||||||
meta( name="description", content="{{pkg.name}} server details" )
|
meta( name="description", content="{{pkg.name}} Server Setup" )
|
||||||
meta( name="viewport", content="width=device-width, initial-scale=1" )
|
meta( name="viewport", content="width=device-width, initial-scale=1" )
|
||||||
link( rel="shortcut icon", href="client/images/favicon/app-16-32.ico" )
|
link( rel="shortcut icon", href="client/images/favicon/favicon-16-32.ico" )
|
||||||
link( rel="apple-touch-icon-precomposed", type="image/png", href="client/images/favicon/app-152.png" )
|
link( rel="apple-touch-icon-precomposed", type="image/png", href="client/images/favicon/favicon-152.png" )
|
||||||
link( rel="stylesheet", href="//fonts.googleapis.com/css?family=Ubuntu+Mono:400,700,400italic,700italic|Ubuntu:300italic,700italic,300,700" )
|
link( rel="stylesheet", href="//fonts.googleapis.com/css?family=Ubuntu+Mono:400,700,400italic,700italic|Ubuntu:300italic,700italic,300,700" )
|
||||||
link( rel="stylesheet", href="client/css/styles.css" )
|
link( rel="stylesheet", href="client/css/styles.css" )
|
||||||
script( src="client/js/scripts.js", data-mode="info" )
|
script( src="client/js/scripts.js", data-mode="info" )
|
||||||
|
@ -28,59 +28,6 @@ html.no-js.browser( lang="en" )
|
||||||
|
|
||||||
h2 Server Setup
|
h2 Server Setup
|
||||||
ul#tests
|
ul#tests
|
||||||
li.test.php( data-id="php_version" )
|
|
||||||
span.label PHP version
|
|
||||||
span.result ?
|
|
||||||
div.info PHP version >= 5.3.0
|
|
||||||
li.test( data-id="cache_dir" )
|
|
||||||
span.label Cache directory
|
|
||||||
span.result ?
|
|
||||||
div.info Web server has write access
|
|
||||||
li.test( data-id="image_thumbs" )
|
|
||||||
span.label Image thumbs
|
|
||||||
span.result ?
|
|
||||||
div.info PHP GD extension with JPEG support available
|
|
||||||
li.test( data-id="exif_thumbs" )
|
|
||||||
span.label Use EXIF thumbs
|
|
||||||
span.result ?
|
|
||||||
div.info PHP EXIF extension available
|
|
||||||
li.test( data-id="movie_thumbs" )
|
|
||||||
span.label Movie thumbs
|
|
||||||
span.result ?
|
|
||||||
div.info
|
|
||||||
| Command line program
|
|
||||||
code ffmpeg
|
|
||||||
| or
|
|
||||||
code avconv
|
|
||||||
| available
|
|
||||||
li.test( data-id="pdf_thumbs" )
|
|
||||||
span.label PDF thumbs
|
|
||||||
span.result ?
|
|
||||||
div.info
|
|
||||||
| Command line program
|
|
||||||
code convert
|
|
||||||
| available
|
|
||||||
li.test( data-id="shell_tar" )
|
|
||||||
span.label Shell tar
|
|
||||||
span.result ?
|
|
||||||
div.info
|
|
||||||
| Command line program
|
|
||||||
code tar
|
|
||||||
| available
|
|
||||||
li.test( data-id="shell_zip" )
|
|
||||||
span.label Shell zip
|
|
||||||
span.result ?
|
|
||||||
div.info
|
|
||||||
| Command line program
|
|
||||||
code zip
|
|
||||||
| available
|
|
||||||
li.test( data-id="folder_sizes" )
|
|
||||||
span.label Folder sizes
|
|
||||||
span.result ?
|
|
||||||
div.info
|
|
||||||
| Command line program
|
|
||||||
code du
|
|
||||||
| available
|
|
||||||
|
|
||||||
div#bottombar.clearfix
|
div#bottombar.clearfix
|
||||||
span.left
|
span.left
|
||||||
|
|
|
@ -15,8 +15,8 @@ html.no-js.browser( lang="en" )
|
||||||
title index · styled with {{pkg.name}} {{pkg.version}} ({{pkg.url}})
|
title index · styled with {{pkg.name}} {{pkg.version}} ({{pkg.url}})
|
||||||
meta( name="description", content="index styled with {{pkg.name}} {{pkg.version}} ({{pkg.url}})" )
|
meta( name="description", content="index styled with {{pkg.name}} {{pkg.version}} ({{pkg.url}})" )
|
||||||
meta( name="viewport", content="width=device-width, initial-scale=1" )
|
meta( name="viewport", content="width=device-width, initial-scale=1" )
|
||||||
link( rel="shortcut icon", href!="#{app_href}client/images/favicon/app-16-32.ico" )
|
link( rel="shortcut icon", href!="#{app_href}client/images/favicon/favicon-16-32.ico" )
|
||||||
link( rel="apple-touch-icon-precomposed", type="image/png", href!="#{app_href}client/images/favicon/app-152.png" )
|
link( rel="apple-touch-icon-precomposed", type="image/png", href!="#{app_href}client/images/favicon/favicon-152.png" )
|
||||||
link( rel="stylesheet", href="//fonts.googleapis.com/css?family=Ubuntu+Mono:400,700,400italic,700italic|Ubuntu:300italic,700italic,300,700" )
|
link( rel="stylesheet", href="//fonts.googleapis.com/css?family=Ubuntu+Mono:400,700,400italic,700italic|Ubuntu:300italic,700italic,300,700" )
|
||||||
link( rel="stylesheet", href!="#{app_href}client/css/styles.css" )
|
link( rel="stylesheet", href!="#{app_href}client/css/styles.css" )
|
||||||
script( src!="#{app_href}client/js/scripts.js" )
|
script( src!="#{app_href}client/js/scripts.js" )
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue