ignore scripts/theme folder
removed files from the script/theme folder under assets because this content will be changed dynamically when a site is published
This commit is contained in:
parent
68469d958b
commit
4723db98d5
3 changed files with 2 additions and 43 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -38,8 +38,9 @@ public/assets/*
|
||||||
!public/assets/css/
|
!public/assets/css/
|
||||||
public/assets/css/*
|
public/assets/css/*
|
||||||
!public/assets/css/dash
|
!public/assets/css/dash
|
||||||
|
# ignore scripts/theme because contents will
|
||||||
|
# change based on theme
|
||||||
!public/assets/scripts/
|
!public/assets/scripts/
|
||||||
!public/assets/scripts/theme/
|
|
||||||
public/assets/scripts/theme/*
|
public/assets/scripts/theme/*
|
||||||
# images
|
# images
|
||||||
!public/assets/images/
|
!public/assets/images/
|
||||||
|
|
|
@ -1,33 +0,0 @@
|
||||||
import Nav from './NavControl.js';
|
|
||||||
import Audio from './AudioControl.js';
|
|
||||||
|
|
||||||
export default class Base {
|
|
||||||
//--------------------------
|
|
||||||
// constructor
|
|
||||||
//--------------------------
|
|
||||||
constructor() {
|
|
||||||
this.currentSlide = 0;
|
|
||||||
this.slides = document.querySelectorAll('.slide');
|
|
||||||
this.nav = new Nav();
|
|
||||||
if (document.querySelector('[role="page-meta"]')) {
|
|
||||||
let audio = new Audio();
|
|
||||||
}
|
|
||||||
this.start();
|
|
||||||
}
|
|
||||||
start() {
|
|
||||||
if (this.slides.length > 1) {
|
|
||||||
this.slideInterval = setInterval(() => {
|
|
||||||
this.slides[this.currentSlide].className = 'hide';
|
|
||||||
this.currentSlide = (this.currentSlide + 1) % this.slides.length;
|
|
||||||
this.slides[this.currentSlide].className = 'show';
|
|
||||||
}, 3000);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//--------------------------
|
|
||||||
// methods
|
|
||||||
//--------------------------
|
|
||||||
|
|
||||||
//--------------------------
|
|
||||||
// event handlers
|
|
||||||
//--------------------------
|
|
||||||
}
|
|
|
@ -1,9 +0,0 @@
|
||||||
import Base from "./Base.js";
|
|
||||||
|
|
||||||
document.addEventListener(
|
|
||||||
"DOMContentLoaded",
|
|
||||||
function () {
|
|
||||||
var base = new Base();
|
|
||||||
},
|
|
||||||
false
|
|
||||||
);
|
|
Loading…
Reference in a new issue