Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Jan Grewe
WiPho
Commits
ea4be3ee
Commit
ea4be3ee
authored
Mar 08, 2015
by
Jan Grewe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improve webinterface design
parent
ddc01303
Pipeline
#2
passed with stage
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
51 additions
and
14 deletions
+51
-14
public/images/bg.png
public/images/bg.png
+0
-0
public/images/no_photo.png
public/images/no_photo.png
+0
-0
public/javascripts/wipho.js
public/javascripts/wipho.js
+37
-11
public/stylesheets/wipho.css
public/stylesheets/wipho.css
+13
-2
views/index.jade
views/index.jade
+1
-1
No files found.
public/images/bg.png
0 → 100644
View file @
ea4be3ee
36.3 KB
public/images/no_photo.png
0 → 100644
View file @
ea4be3ee
141 KB
public/javascripts/wipho.js
View file @
ea4be3ee
$
(
document
).
ready
(
function
()
{
$
(
'
body
'
).
height
(
$
(
window
).
height
());
$
(
'
body
'
).
height
(
$
(
window
).
height
());
centerImage
();
getLatest
();
setInterval
(
function
()
{
getLatest
();
},
3000
);
getLatest
();
setInterval
(
function
()
{
getLatest
();
},
1000
);
$
(
window
).
resize
(
function
()
{
centerImage
();
});
$
(
'
#latest
'
).
one
(
'
load
'
,
function
(){
$
(
this
).
one
(
'
load
'
,
function
(){
$
(
this
).
addClass
(
'
imgBorder
'
);
});
});
$
(
'
#latest
'
).
on
(
'
load
'
,
function
(){
centerImage
();
$
(
this
).
animate
({
opacity
:
1
},
400
);
});
});
function
getLatest
()
{
$
.
getJSON
(
'
/latest
'
,
function
(
data
)
{
if
(
'
/previews/
'
+
data
.
name
!=
$
(
'
#latest
'
).
attr
(
'
src
'
))
{
$
(
'
#latest
'
).
attr
(
'
src
'
,
'
/previews/
'
+
data
.
name
);
}
});
$
.
getJSON
(
'
/latest
'
,
function
(
data
)
{
if
(
'
/previews/
'
+
data
.
name
!=
$
(
'
#latest
'
).
attr
(
'
src
'
))
{
$
(
'
#latest
'
).
animate
({
opacity
:
0
},
400
,
function
()
{
$
(
this
).
attr
(
'
src
'
,
'
/previews/
'
+
data
.
name
);
});
}
});
}
function
centerImage
()
{
$
(
'
#latest
'
).
css
({
position
:
'
absolute
'
,
left
:
(
$
(
window
).
width
()
-
$
(
'
#latest
'
).
outerWidth
())
/
2
,
top
:
(
$
(
window
).
height
()
-
$
(
'
#latest
'
).
outerHeight
())
/
2
,
});
}
\ No newline at end of file
public/stylesheets/wipho.css
View file @
ea4be3ee
body
{
overflow
:
hidden
;
margin
:
0px
;
padding
:
0px
;
background-color
:
#000000
;
background-image
:
url("../images/bg.png")
;
}
a
{
...
...
@@ -8,6 +11,14 @@ a {
}
#latest
{
max-width
:
100%
;
max-height
:
100%
;
margin-top
:
-0.5%
;
max-width
:
93%
;
max-height
:
93%
;
}
.imgBorder
{
border
:
solid
5px
#222
;
-moz-box-shadow
:
5px
5px
15px
#000
;
-webkit-box-shadow
:
5px
5px
15px
#000
;
box-shadow
:
5px
5px
15px
#000
;
}
\ No newline at end of file
views/index.jade
View file @
ea4be3ee
...
...
@@ -3,4 +3,4 @@ extends layout
block content
//h1= title
//p Welcome to #{title}
img(id='latest' src='')
\ No newline at end of file
img(id='latest' src='images/no_photo.png')
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment