home page tape viwer init update;

This commit is contained in:
tmshv committed 2015-07-08 20:30:29 +03:00
1 parent 2417b93399
commit a966030506
3 files changed
+26 -4

No files matched your search

+6
View File
@@ -3,6 +3,12 @@
max-width: 1000px;
margin: 2em auto;
&.simplified{
.tape{
display: none;
}
}
}
.tape-block-content{
+19 -1
View File
@@ -4,8 +4,26 @@
module.exports = function (app) {
app.controller("HomePageController", function ($scope, config) {
var fotorama;
$scope.pageClass = "page-home";
$(".fotorama").fotorama();
var $tape = $('.tape-block');
var $fotorama = $('.fotorama');
$tape.addClass('simplified');
$fotorama.on('fotorama:ready', function () {
$tape.removeClass('simplified');
fotorama.setOptions({
nav: 'dots'
});
});
fotorama = $fotorama.fotorama().data('fotorama');
fotorama.load([
{img: 'http://static.shburg.org/art/img/cat1.jpg'},
{img: 'http://static.shburg.org/art/img/cat2.jpg'},
{img: 'http://static.shburg.org/art/img/cat3.jpg'}
]);
});
};
+1 -3
View File
@@ -24,13 +24,11 @@
<div class="fotorama"
data-transition="crossfade"
data-autoplay="6000"
data-nav="false"
data-arrows="false"
data-width="100%"
data-fit="cover"
data-loop="true">
<img src="http://static.shburg.org/art/img/cat1.jpg" alt="">
<img src="http://static.shburg.org/art/img/cat2.jpg" alt="">
<img src="http://static.shburg.org/art/img/cat3.jpg" alt="">
</div>
</div>
</div>