home page -> school page; + PageSchool component
This commit is contained in:
1 parent
5c72276b5e
commit
57141313e9
7 files changed
+52
-50
No files matched your search
+3
-6
@@ -16,8 +16,9 @@ import ScheduleSlide from './components/ScheduleSlide';
|
|||||||
import ScheduleRecord from './components/ScheduleRecord';
|
import ScheduleRecord from './components/ScheduleRecord';
|
||||||
import FooterLinks from './components/FooterLinks';
|
import FooterLinks from './components/FooterLinks';
|
||||||
|
|
||||||
|
import PageSchool from './components/PageSchool';
|
||||||
|
|
||||||
import AppController from './controllers/AppController';
|
import AppController from './controllers/AppController';
|
||||||
import HomeController from './controllers/HomeController';
|
|
||||||
import ScheduleController from './controllers/ScheduleController';
|
import ScheduleController from './controllers/ScheduleController';
|
||||||
import CollectiveController from './controllers/CollectiveController';
|
import CollectiveController from './controllers/CollectiveController';
|
||||||
import GalleryController from './controllers/GalleryController';
|
import GalleryController from './controllers/GalleryController';
|
||||||
@@ -89,8 +90,8 @@ app.run(($location, $rootScope, $http) => {
|
|||||||
GalleryItem,
|
GalleryItem,
|
||||||
AlbumCollection,
|
AlbumCollection,
|
||||||
TeacherProfile,
|
TeacherProfile,
|
||||||
|
PageSchool,
|
||||||
AppController,
|
AppController,
|
||||||
HomeController,
|
|
||||||
ScheduleController,
|
ScheduleController,
|
||||||
CollectiveController,
|
CollectiveController,
|
||||||
GalleryController,
|
GalleryController,
|
||||||
@@ -105,10 +106,6 @@ app.run(($location, $rootScope, $http) => {
|
|||||||
ScheduleRecord,
|
ScheduleRecord,
|
||||||
FooterLinks,
|
FooterLinks,
|
||||||
function (app) {
|
function (app) {
|
||||||
app.controller('HomePageController', ($scope) => {
|
|
||||||
$scope.pageClass = 'page-home';
|
|
||||||
});
|
|
||||||
|
|
||||||
app.controller('SchedulePageController', ($scope) => {
|
app.controller('SchedulePageController', ($scope) => {
|
||||||
$scope.pageClass = 'page-schedule';
|
$scope.pageClass = 'page-schedule';
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -0,0 +1,37 @@
|
|||||||
|
import template from '../../templates/components/page-school.html';
|
||||||
|
|
||||||
|
export default function (app) {
|
||||||
|
app.component('pageSchool', {
|
||||||
|
template: template,
|
||||||
|
controller: () => {
|
||||||
|
this.pageClass = 'page-school';
|
||||||
|
|
||||||
|
let fotorama;
|
||||||
|
let $tape = $('.tape-block');
|
||||||
|
let $fotorama = $tape.find('.tape-block__content');
|
||||||
|
|
||||||
|
$tape.addClass('simplified');
|
||||||
|
$fotorama.on('fotorama:ready', () => {
|
||||||
|
$tape.removeClass('simplified');
|
||||||
|
fotorama.setOptions({
|
||||||
|
nav: 'dots',
|
||||||
|
transition: 'crossfade',
|
||||||
|
autoplay: '6000',
|
||||||
|
arrows: 'false',
|
||||||
|
width: '100%',
|
||||||
|
fit: 'cover',
|
||||||
|
loop: 'true'
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
fotorama = $fotorama.fotorama().data('fotorama');
|
||||||
|
setTimeout(() => {
|
||||||
|
fotorama.load([
|
||||||
|
{img: 'https://static.shburg.org/art/img/cat1.jpg'},
|
||||||
|
{img: 'https://static.shburg.org/art/img/cat2.jpg'},
|
||||||
|
{img: 'https://static.shburg.org/art/img/cat3.jpg'}
|
||||||
|
]);
|
||||||
|
}, 100);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
@@ -22,8 +22,7 @@ export let collectiveSortPattern = [
|
|||||||
export let routes = [
|
export let routes = [
|
||||||
{
|
{
|
||||||
name: '/',
|
name: '/',
|
||||||
templateUrl: '/views/home.html',
|
template: '<page-school></page-school>',
|
||||||
controller: 'HomePageController',
|
|
||||||
title: 'ДХШ Шлиссельбурга'
|
title: 'ДХШ Шлиссельбурга'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,30 +0,0 @@
|
|||||||
export default function (app) {
|
|
||||||
app.controller('HomeController', () => {
|
|
||||||
let fotorama;
|
|
||||||
let $tape = $('.tape-block');
|
|
||||||
let $fotorama = $tape.find('.tape-block__content');
|
|
||||||
|
|
||||||
$tape.addClass('simplified');
|
|
||||||
$fotorama.on('fotorama:ready', () => {
|
|
||||||
$tape.removeClass('simplified');
|
|
||||||
fotorama.setOptions({
|
|
||||||
nav: 'dots',
|
|
||||||
transition: 'crossfade',
|
|
||||||
autoplay: '6000',
|
|
||||||
arrows: 'false',
|
|
||||||
width: '100%',
|
|
||||||
fit: 'cover',
|
|
||||||
loop: 'true'
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
fotorama = $fotorama.fotorama().data('fotorama');
|
|
||||||
setTimeout(() => {
|
|
||||||
fotorama.load([
|
|
||||||
{img: 'https://static.shburg.org/art/img/cat1.jpg'},
|
|
||||||
{img: 'https://static.shburg.org/art/img/cat2.jpg'},
|
|
||||||
{img: 'https://static.shburg.org/art/img/cat3.jpg'}
|
|
||||||
]);
|
|
||||||
}, 100);
|
|
||||||
});
|
|
||||||
};
|
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
.page-school {
|
||||||
|
&.ng-leave {
|
||||||
|
transform-origin: 0% 0%;
|
||||||
|
animation: rotateFall .3s both ease-in;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.ng-enter {
|
||||||
|
animation: scaleUp 0.3s both ease-in;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -5,17 +5,6 @@
|
|||||||
&.ng-enter {}
|
&.ng-enter {}
|
||||||
}
|
}
|
||||||
|
|
||||||
.page-home {
|
|
||||||
&.ng-leave {
|
|
||||||
transform-origin: 0% 0%;
|
|
||||||
animation: rotateFall .3s both ease-in;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.ng-enter {
|
|
||||||
animation: scaleUp 0.3s both ease-in;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-schedule {
|
.page-schedule {
|
||||||
&.ng-leave {
|
&.ng-leave {
|
||||||
transform-origin: 0% 0%;
|
transform-origin: 0% 0%;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<div class="content content_thin" ng-controller="HomeController">
|
<div class="content content_thin">
|
||||||
<div class="main-block">
|
<div class="main-block">
|
||||||
<!--<div>-->
|
<!--<div>-->
|
||||||
<!--<!–<a href="tel://{{telephone}}"></a>–>-->
|
<!--<!–<a href="tel://{{telephone}}"></a>–>-->
|
||||||
Reference in new issue
Block a user