-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
418 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# this is required for static file buildpack |
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
worker_processes 1; | ||
daemon off; | ||
|
||
error_log <%= ENV["APP_ROOT"] %>/nginx/logs/error.log; | ||
events { worker_connections 1024; } | ||
|
||
http { | ||
log_format cloudfoundry '$http_x_forwarded_for - $http_referer - [$time_local] "$request" $status $body_bytes_sent'; | ||
access_log <%= ENV["APP_ROOT"] %>/nginx/logs/access.log cloudfoundry; | ||
default_type application/octet-stream; | ||
include mime.types; | ||
sendfile on; | ||
gzip on; | ||
tcp_nopush on; | ||
keepalive_timeout 30; | ||
|
||
server { | ||
listen <%= ENV["PORT"] %>; | ||
server_name localhost; | ||
|
||
location ~ /\.ht { deny all; } | ||
location / { | ||
root <%= ENV["APP_ROOT"] %>/public; | ||
index index.html index.htm Default.htm; | ||
} | ||
|
||
error_page 404 /404.html; | ||
location /404.html { | ||
root <%= ENV["APP_ROOT"] %>/public; | ||
internal; | ||
} | ||
} | ||
} |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
/* Stylesheet swappin */ | ||
$(document).ready(function(){ | ||
$('input.alternate-css').change(function() { | ||
if($(this).get(0).checked) { | ||
$("link[href*='prism-okaida.css']").attr('disabled', 'disabled'); | ||
$("link[href*='prism-default.css']").removeAttr('disabled'); | ||
} else { | ||
$("link[href*='prism-okaida.css']").removeAttr('disabled'); | ||
$("link[href*='prism-default.css']").attr('disabled', 'disabled'); | ||
} | ||
}); | ||
}); | ||
|
||
/* Adjust scrollTop when navigating to a subsection on the current page */ | ||
|
||
$(document).ready(function() { | ||
$('a.styleguide-subsection, .section-nav a').click(function(e) { | ||
var $target = $(e.target.hash); | ||
var desiredScrollPosition = $target.offset().top; | ||
window.history.pushState('', '', e.target.hash); | ||
$('body, html').animate({ | ||
scrollTop: desiredScrollPosition | ||
}, 500, function () { | ||
$target.focus(); | ||
}); | ||
return false; | ||
}); | ||
}); | ||
|
||
/* Make all links inside codeExamples open in a new window */ | ||
|
||
$(document).ready(function() { | ||
$('.codeExample a').attr('target', '_blank'); | ||
}); | ||
|
||
/* Navbar hamburger functionality */ | ||
|
||
$(document).ready(function() { | ||
$('#navbar-hamburger').click(function() { | ||
$('ul#styleguide-first-level-nav').slideToggle(300); | ||
}); | ||
|
||
$('.styleguide-second-level-nav-link').click(function(e) { | ||
e.preventDefault(); | ||
|
||
var $targetCategory = $('#' + $(e.currentTarget).data('target')); | ||
var targetCategoryClosed = !$targetCategory.hasClass('active'); | ||
|
||
$('li.styleguide-category').removeClass('active'); | ||
$('ul.styleguide-second-level-nav').slideUp(); | ||
if (targetCategoryClosed) { | ||
$targetCategory.addClass('active'); | ||
$targetCategory.find('ul.styleguide-second-level-nav').slideDown(); | ||
} | ||
}); | ||
}); |
Oops, something went wrong.