diff --git a/website/_harp.json b/website/_harp.json index bf31be30c..b75e2fd3b 100644 --- a/website/_harp.json +++ b/website/_harp.json @@ -80,6 +80,7 @@ } ], + "ALPHA": true, "V_CSS": "1.6", "V_JS": "1.2", "DEFAULT_SYNTAX": "python", diff --git a/website/_includes/_navigation.jade b/website/_includes/_navigation.jade index d319ef2c9..320882807 100644 --- a/website/_includes/_navigation.jade +++ b/website/_includes/_navigation.jade @@ -9,6 +9,9 @@ nav.c-nav.u-text.js-nav(class=landing ? "c-nav--theme" : null) .u-text-label.u-padding-small.u-hidden-xs=SUBSECTION ul.c-nav__menu + if ALPHA + - var NAVIGATION = { "Usage": "/docs/usage", "Reference": "/docs/api" } + each url, item in NAVIGATION li.c-nav__menu__item(class=(url == "/") ? "u-hidden-xs" : null) +a(url)=item diff --git a/website/_includes/_page-docs.jade b/website/_includes/_page-docs.jade index 72db134cd..ec2751c4d 100644 --- a/website/_includes/_page-docs.jade +++ b/website/_includes/_page-docs.jade @@ -10,6 +10,14 @@ main.o-main.o-main--sidebar.o-main--aside if tag +tag=tag + if ALPHA + +infobox("⚠️ You are viewing the spaCy v2.0 alpha docs") + | This page is part of the alpha documentation for spaCy v2.0 + | and does not reflect the state of the latest stable release. + | #[+a("#") See here] for more information on how to install + | and test the new version. To read the official docs for + | v1.x, #[+a("https://spacy.io/docs") go here]. + !=yield +grid.o-content.u-text diff --git a/website/_layout.jade b/website/_layout.jade index ccca2863f..f0828fb33 100644 --- a/website/_layout.jade +++ b/website/_layout.jade @@ -35,7 +35,10 @@ html(lang="en") link(rel="shortcut icon" href="/assets/img/favicon.ico") link(rel="icon" type="image/x-icon" href="/assets/img/favicon.ico") - if SUBSECTION == "usage" + if ALPHA && SECTION == "docs" + link(href="/assets/css/style_green.css?v#{V_CSS}" rel="stylesheet") + + else if SUBSECTION == "usage" link(href="/assets/css/style_red.css?v#{V_CSS}" rel="stylesheet") else