Skip to content

Commit f937d2f

Browse files
authored
Merge pull request #126 from rackerlabs/docs-tweaks
Docs tweaks
2 parents 44f2d89 + 06de5f2 commit f937d2f

File tree

8 files changed

+14
-40
lines changed

8 files changed

+14
-40
lines changed

docs/_data/nav.json5

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,6 @@
77
]
88
},
99

10-
{
11-
label: 'Styleguide',
12-
path: 'styleguide',
13-
children: [
14-
//{ label: 'Colors', path: 'colors' },
15-
{ label: 'Iconography', path: 'iconography' },
16-
{ label: 'Typography', path: 'typography' },
17-
]
18-
},
19-
2010
/*
2111
{
2212
label: 'Asset Stability',
@@ -33,7 +23,9 @@
3323
{ label: 'Breadcrumbs', path: 'breadcrumbs' },
3424
{ label: 'Buttons', path: 'buttons' },
3525
{ label: 'Checkboxes', path: 'checkboxes' },
26+
//{ label: 'Colors', path: 'colors' },
3627
{ label: 'Grid', path: 'grid' },
28+
{ label: 'Icons', path: 'icons' },
3729
{
3830
label: 'Layouts',
3931
path: 'layouts',
@@ -54,6 +46,7 @@
5446
{ label: 'Tabs', path: 'tabs' },
5547
{ label: 'Text Inputs', path: 'text-inputs' },
5648
{ label: 'Tooltips', path: 'tooltips' },
49+
{ label: 'Typography', path: 'typography' },
5750
],
5851
},
5952

docs/_templates/partials/footer_nav.njk

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,6 @@
88
{{ page.updated.format(site.dateFormat) }}
99
</small>
1010
{% endif %}
11+
12+
<small>(v{{VERSION}})</small>
1113
</div>

docs/_templates/styleguide.njk

Lines changed: 0 additions & 18 deletions
This file was deleted.

docs/styleguide/iconography/index.html renamed to docs/components/icons/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
2-
title: Iconography
2+
title: Icons
33
also:
44
elements/hx-icon: <hx-icon>
55
---
6-
{% extends 'styleguide.njk' %}
6+
{% extends 'component.njk' %}
77
{% block content %}
88
<section>
99
<h2 class="hxSectionTitle" id="demo">Demo</h2>

docs/styleguide/typography/index.html renamed to docs/components/typography/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Typography
33
---
4-
{% extends 'styleguide.njk' %}
4+
{% extends 'component.njk' %}
55
{% block content %}
66
<section><!-- Font -->
77
<h2 class="hxSectionTitle" id="font-weight">Font Weight</h2>

docs/elements/hx-icon/index.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: <hx-icon>
33
also:
4-
styleguide/iconography: Iconography
4+
components/icons: Icons
55
---
66
{% extends 'element.njk' %}
77
{% block content %}
@@ -28,8 +28,8 @@
2828
<dl>
2929
<dt>type</dt>
3030
<dd>
31-
Changes the displayed icon to one of the
32-
<a href="styleguide/iconography/#available-icons">available icons</a>
31+
Changes the displayed icon to one of the
32+
<a href="components/icons/#available-icons">available icons</a>
3333
</dd>
3434
</dl>
3535
{% endblock %}

lib/context.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
'use strict';
22

33
const CONFIG = require('../_config');
4+
const JSON5 = require('json5');
5+
const PKG = require('../package.json');
46
const _ = require('lodash');
57
const fm = require('front-matter');
68
const fs = require('fs');
79
const globby = require('globby');
810
const moment = require('moment');
911
const path = require('path');
10-
const JSON5 = require('json5');
1112

1213
// Fetch data from {CONFIG.docsDir}/_data
1314
function _getDataContext () {
@@ -66,6 +67,7 @@ function forFile (relPath) {
6667
site: CONFIG.site,
6768
data: _getDataContext(),
6869
page: _getPageContext(relPath),
70+
VERSION: PKG.version,
6971
};
7072
}//forFile
7173

test/visreg/visreg.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,6 @@ export function suite(browserName: string) {
3535
await snap("{browserName}/nav/guides", $(util.selectors.nav));
3636
});
3737

38-
test("nav/styleguide", async () => {
39-
await util.$x(driver, "//nav//hx-disclosure", "Styleguide").click()
40-
await snap("{browserName}/nav/styleguide", $(util.selectors.nav));
41-
});
42-
4338
test("nav/components", async () => {
4439
await util.$x(driver, "//nav//hx-disclosure", "Components").click();
4540
await snap("{browserName}/nav/components", $(util.selectors.nav));

0 commit comments

Comments
 (0)