Skip to content
This repository has been archived by the owner on Nov 28, 2018. It is now read-only.

Commit

Permalink
Merge pull request #5 from andela-angene/course-landing-page
Browse files Browse the repository at this point in the history
Course landing page
  • Loading branch information
Anthony Ngene authored Aug 13, 2017
2 parents a8d398f + 079e0ff commit 219b9f9
Show file tree
Hide file tree
Showing 17 changed files with 1,036 additions and 442 deletions.
58 changes: 58 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{
"extends": "airbnb/legacy",
"env": {
"jquery": true,
"browser": true
},
"rules": {
"max-len": [
2,
100,
2
],
"one-var": 0,
"one-var-declaration-per-line": 0,
"no-unused-vars": 0,
"new-cap": 0,
"consistent-return": 0,
"no-param-reassign": 0,
"comma-dangle": 0,
"curly": [
"error",
"multi-line"
],
"import/no-unresolved": 0,
"no-shadow": [
"error",
{
"allow": [
"req",
"res",
"err"
]
}
],
"valid-jsdoc": [
"error",
{
"requireReturn": true,
"requireReturnType": true,
"requireParamDescription": false,
"requireReturnDescription": true
}
],
"require-jsdoc": [
"error",
{
"require": {
"FunctionDeclaration": false,
"MethodDefinition": true,
"ClassDeclaration": true
}
}
]
},
"plugins": [
"import"
]
}
6 changes: 6 additions & 0 deletions .hound.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
eslint:
enabled: true
config_file: .eslintrc.json
ignore_file: .eslintignore
scss:
enabled: false
4 changes: 4 additions & 0 deletions coursebuilder/modules/explorer/_static/css/style.css

Large diffs are not rendered by default.

62 changes: 31 additions & 31 deletions coursebuilder/modules/explorer/_static/js/main.js
Original file line number Diff line number Diff line change
@@ -1,50 +1,50 @@
$(document).ready(function(){
$(document).ready(function documentReady() {
$(".button-collapse").sideNav();

$('.awards-carousel').owlCarousel({
loop:true,
margin:10,
nav:true,
loop: true,
margin: 10,
nav: true,
dots: false,
navText: ['<i class="ion-ios-arrow-left"></i>', '<i class="ion-ios-arrow-right"></i>'],
responsive:{
0:{
items:1
responsive: {
0: {
items: 1
},
600:{
items:2
600: {
items: 2
},
1000:{
items:4
1000: {
items: 4
}
}
});

$('.how-carousel').owlCarousel({
loop:true,
margin:10,
nav:true,
loop: true,
margin: 10,
nav: true,
navText: ['<i class="ion-ios-arrow-left"></i>', '<i class="ion-ios-arrow-right"></i>'],
items: 1,
items: 1
});


function showPage(pageName) {
$('.page-wrapper').hide();
$('#' + pageName).show();
}
function showPage(pageName) {
$('.page-wrapper').hide();
$('#' + pageName).show();
}

var pageLinks = ['explorer', 'certification', 'homepage', 'tools', 'partners', 'feedback'];
var pageLinks = ['explorer', 'certification', 'homepage', 'tools', 'partners', 'feedback'];

pageLinks.forEach(function (name) {
$('a[href="#!' + name + '"]').on('click', function () {
showPage(name);
});
pageLinks.forEach(function addLinks(name) {
$('a[href="#!' + name + '"]').on('click', function showPageEvent() {
showPage(name);
});

if (window.location.href.substr(-name.length) === name) {
showPage(name);
}
})
if (window.location.href.substr(-name.length) === name) {
showPage(name);
}
});

$('select').material_select();
$('select').material_select();
});
Loading

0 comments on commit 219b9f9

Please sign in to comment.