home page tape viwer init update;
This commit is contained in:
1 parent
2417b93399
commit
a966030506
3 files changed
+26
-4
No files matched your search
@@ -3,6 +3,12 @@
|
||||
max-width: 1000px;
|
||||
|
||||
margin: 2em auto;
|
||||
|
||||
&.simplified{
|
||||
.tape{
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.tape-block-content{
|
||||
|
||||
+19
-1
@@ -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'}
|
||||
]);
|
||||
});
|
||||
};
|
||||
@@ -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>
|
||||
|
||||
Reference in new issue
Block a user