Skip to content
Snippets Groups Projects
Commit fbb7d3bd authored by Christopher Guindon's avatar Christopher Guindon
Browse files

Update solstice template


Signed-off-by: Christopher Guindon's avatarChristopher Guindon <chris.guindon@eclipse-foundation.org>
parent 44070107
No related branches found
No related tags found
No related merge requests found
......@@ -10,7 +10,7 @@ module.exports = function (grunt) {
'separator': '\\n',
'includePath': 'src',
'themeTemplate': 'templates/index.jade',
//'themeFullWidth': true,
'themeFullWidth': true,
'themeStyle': 'styles/styles.less'
}
}
......
This diff is collapsed.
FORMAT: 1A
HOST: https://api.eclipse.org
# Eclipse Api RESTful API
Eclipse Fountation resources and data.
# Eclipse RESTful API
This describes the resources that make up the official Eclipse Foundation REST API.
If you have any problems or requests please contact [Christopher Guindon](mailto:chris.guindon@eclipse-foundation.org) .
### Rate Limit
This API currently limits users to 1000 authenticated requests and 1000 anonymous requests an hour.
......@@ -16,7 +18,9 @@ a curl request to the eclipse_profile API, to find out how many org_eclipse_oomp
The -I parameter indicates that we only care about the headers, not the content.
In examining the result, you’ll notice some information in the Link header that looks like this:
```<https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=2&amp;pagesize=2>; rel="next", <https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=27&amp;pagesize=2>; rel="last", <https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=1&amp;pagesize=2>; rel="first", <https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=1&amp;pagesize=2>; rel="self"```
```
<https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=2&amp;pagesize=2>; rel="next", <https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=27&amp;pagesize=2>; rel="last", <https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=1&amp;pagesize=2>; rel="first", <https://api.eclipse.org/api/blob/KJBNCEW08231nkJKCEW32898239?page=1&amp;pagesize=2>; rel="self"
```
Let’s break that down. rel="next" says that the next page is page=2. This makes sense, since by default,
all paginated queries start at page 1. rel="last" provides some more information, stating that the last page of results is on page 27.
......
@import url("../bower_components/solstice/stylesheets/_core/barebone/styles.less");
header.thin-header{
border-bottom:none;
position:fixed;
width:100%;
margin:0;
top:0;
background:#fff;
z-index:999;
@media (min-width: 768px) {
padding:10px;
}
boder-color:#D9D9D5;
}
body,html{
padding:0;
margin:0;
}
nav,
.container-content{
margin-top:65px;
padding-left:15px;
}
\ No newline at end of file
......@@ -2,7 +2,7 @@
<div class="container-fluid">
<div class="row" id="header-row">
<div class="col-sm-6 col-md-6 col-lg-5 padding-left-0" id="header-left">
<div class="wrapper-logo-default padding-top-10"><a href="https://www.eclipse.org/"><img class="logo-eclipse-default img-responsive hidden-xs" alt="logo" src="//www.eclipse.org/eclipse.org-common/themes/solstice/public/images/logo/eclipse-426x100.png"/></a></div>
<div class="wrapper-logo-default"><a href="https://www.eclipse.org/"><img class="logo-eclipse-default img-responsive hidden-xs" alt="logo" src="//www.eclipse.org/eclipse.org-common/themes/solstice/public/images/logo/eclipse-426x100.png"/></a></div>
</div>
<div class="col-sm-18 col-md-18 col-lg-19" id="main-menu-wrapper">
<div class="navbar yamm navbar-right" id="main-menu">
......
......@@ -11,19 +11,19 @@ html
style!= self.css
body.preload.solstice-footer-min#body_solstice
include header.html
a.text-muted.back-to-top(href='#top')
i.fa.fa-toggle-up
| &nbsp;Back to top
div(class=self.fullWidth ? 'container-fluid' : 'container')
div(class=self.fullWidth ? 'container-fluid' : 'container').container-content
.row
block nav
+Nav(false)
.content
block content
include header.html
+Content('primary', false)
p.text-muted(style="text-align: center;")
......@@ -31,7 +31,7 @@ html
| #{self.date().format('YYYY') }
| The Eclipse Foundation. All Rights Reserved.
p.text-muted(style="text-align: center;")
p.text-muted.hide(style="text-align: center;")
| Generated by&nbsp;
a.aglio(href="https://github.com/danielgtaylor/aglio") aglio
| &nbsp;on #{self.date().format('DD MMM YYYY') }
......
......@@ -138,7 +138,7 @@ function refresh(body) {
collapses them.
*/
function autoCollapse() {
var windowHeight = getWindowDimensions()[1];
var windowHeight = (getWindowDimensions()[1])-150;
var itemsHeight = 64; /* Account for some padding */
var itemsArray = Array.prototype.slice.call(
document.querySelectorAll('nav .resource-group .heading'));
......@@ -148,19 +148,27 @@ function autoCollapse() {
itemsHeight += item.parentNode.offsetHeight;
});
// Should we auto-collapse any nav items? Try to find the smallest item
// that can be collapsed to show all items on the screen. If not possible,
// then collapse the largest item and do it again. First, sort the items
// by height from smallest to largest.
var sortedItems = itemsArray.sort(function (a, b) {
return a.parentNode.offsetHeight - b.parentNode.offsetHeight;
});
var sortedItems = itemsArray;
while (sortedItems.length) {
for (var i = 1; i < sortedItems.length+1; i++) {
while (sortedItems.length && itemsHeight > windowHeight) {
for (var i = 0; i < sortedItems.length; i++) {
// Will collapsing this item help?
var itemHeight = sortedItems[i].nextSibling.offsetHeight;
if ((itemsHeight - itemHeight <= windowHeight) || i === sortedItems.length - 1) {
// It will, so let's collapse it, remove its content height from
// our total and then remove it from our list of candidates
// that can be collapsed.
itemsHeight -= itemHeight;
toggleCollapseNav({target: sortedItems[i].children[0]}, true);
sortedItems.splice(i, 1);
break;
}
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment