Skip to content

Commit

Permalink
Updated yuidoc
Browse files Browse the repository at this point in the history
  • Loading branch information
sebi2k1 committed Feb 14, 2016
1 parent 243d82f commit 3c175fa
Show file tree
Hide file tree
Showing 20 changed files with 944 additions and 2,589 deletions.
10 changes: 2 additions & 8 deletions docs/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,19 @@ YUI.add("yuidoc-meta", function(Y) {
"classes": [
"DatabaseService",
"Message",
"RawChannel",
"Signal",
"exports"
],
"modules": [
"CAN",
"Signals"
],
"allModules": [
{
"displayName": "CAN",
"name": "CAN",
"description": "Basic CAN access"
},
{
"displayName": "Signals",
"name": "Signals",
"description": "The Signals modules provides an interface to access the values/signals\nencoded in CAN messages."
}
]
],
"elements": []
} };
});
Binary file modified docs/assets/css/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 3 additions & 2 deletions docs/assets/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ html {
}

body {
font: 13px/1.4 'Lucida Grande', 'Lucida Sans Unicode', 'DejaVu Sans', 'Bitstream Vera Sans', 'Helvetica', 'Arial', sans-serif;
/*font: 13px/1.4 'Lucida Grande', 'Lucida Sans Unicode', 'DejaVu Sans', 'Bitstream Vera Sans', 'Helvetica', 'Arial', sans-serif;*/
font: 13px/1.4 'Helvetica', 'Arial', sans-serif;
margin: 0;
padding: 0;
}
Expand Down Expand Up @@ -97,7 +98,7 @@ code, kbd, pre, samp {
line-height: 1.35;
}

p code, p kbd, p samp {
p code, p kbd, p samp, li code {
background: #FCFBFA;
border: 1px solid #EFEEED;
padding: 0 3px;
Expand Down
Binary file added docs/assets/favicon.ico
Binary file not shown.
Binary file removed docs/assets/favicon.png
Binary file not shown.
6 changes: 5 additions & 1 deletion docs/assets/js/api-filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ Y.APIFilter = Y.Base.create('apiFilter', Y.Base, [Y.AutoCompleteBase], {
}
});

if (this.get('queryType') === 'elements') {
name = '<' + name + '>';
}

return name;
}

Expand All @@ -24,7 +28,7 @@ Y.APIFilter = Y.Base.create('apiFilter', Y.Base, [Y.AutoCompleteBase], {
value: 'phraseMatch'
},

// May be set to "classes" or "modules".
// May be set to "classes", "elements" or "modules".
queryType: {
value: 'classes'
},
Expand Down
8 changes: 6 additions & 2 deletions docs/assets/js/api-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ var Lang = Y.Lang,
APIList = Y.namespace('APIList'),

classesNode = Y.one('#api-classes'),
elementsNode = Y.one('#api-elements'),
inputNode = Y.one('#api-filter'),
modulesNode = Y.one('#api-modules'),
tabviewNode = Y.one('#api-tabview'),
Expand Down Expand Up @@ -97,15 +98,17 @@ tabview.get('panelNode').all('a').each(function (link) {

// -- Private Functions --------------------------------------------------------
function getFilterResultNode() {
return filter.get('queryType') === 'classes' ? classesNode : modulesNode;
var queryType = filter.get('queryType');
return queryType === 'classes' ? classesNode
: queryType === 'elements' ? elementsNode : modulesNode;
}

// -- Event Handlers -----------------------------------------------------------
function onFilterResults(e) {
var frag = Y.one(Y.config.doc.createDocumentFragment()),
resultNode = getFilterResultNode(),
typePlural = filter.get('queryType'),
typeSingular = typePlural === 'classes' ? 'class' : 'module';
typeSingular = typePlural === 'classes' ? 'class' : typePlural === 'elements' ? 'element' : 'module';

if (e.results.length) {
YArray.each(e.results, function (result) {
Expand Down Expand Up @@ -181,6 +184,7 @@ function onTabSelectionChange(e) {
};

switch (name) {
case 'elements':// fallthru
case 'classes': // fallthru
case 'modules':
filter.setAttrs({
Expand Down
12 changes: 9 additions & 3 deletions docs/assets/js/apidocs.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,12 @@ pjax = new Y.Pjax({
callbacks: defaultRoute
},

// -- /elements/* -------------------------------------------------------
{
path : '/elements/:element.html*',
callbacks: defaultRoute
},

// -- /classes/* -------------------------------------------------------
{
path : '/classes/:class.html*',
Expand Down Expand Up @@ -167,7 +173,7 @@ pjax.initLineNumbers = function () {
};

pjax.initRoot = function () {
var terminators = /^(?:classes|files|modules)$/,
var terminators = /^(?:classes|files|elements|modules)$/,
parts = pjax._getPathRoot().split('/'),
root = [],
i, len, part;
Expand Down Expand Up @@ -284,7 +290,7 @@ pjax.handleClasses = function (req, res, next) {
var status = res.ioResponse.status;

// Handles success and local filesystem XHRs.
if (!status || (status >= 200 && status < 300)) {
if (res.ioResponse.readyState === 4 && (!status || (status >= 200 && status < 300))) {
pjax.initClassTabView();
}

Expand All @@ -295,7 +301,7 @@ pjax.handleFiles = function (req, res, next) {
var status = res.ioResponse.status;

// Handles success and local filesystem XHRs.
if (!status || (status >= 200 && status < 300)) {
if (res.ioResponse.readyState === 4 && (!status || (status >= 200 && status < 300))) {
pjax.initLineNumbers();
}

Expand Down
Loading

0 comments on commit 3c175fa

Please sign in to comment.