mirror of
				https://github.com/explosion/spaCy.git
				synced 2025-10-31 07:57:35 +03:00 
			
		
		
		
	Add option for "alpha mode" with warning and green theme
This commit is contained in:
		
							parent
							
								
									f0cc642bb9
								
							
						
					
					
						commit
						fec16d1649
					
				|  | @ -80,6 +80,7 @@ | ||||||
|             } |             } | ||||||
|         ], |         ], | ||||||
| 
 | 
 | ||||||
|  |         "ALPHA": true, | ||||||
|         "V_CSS": "1.6", |         "V_CSS": "1.6", | ||||||
|         "V_JS": "1.2", |         "V_JS": "1.2", | ||||||
|         "DEFAULT_SYNTAX": "python", |         "DEFAULT_SYNTAX": "python", | ||||||
|  |  | ||||||
|  | @ -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 |         .u-text-label.u-padding-small.u-hidden-xs=SUBSECTION | ||||||
| 
 | 
 | ||||||
|     ul.c-nav__menu |     ul.c-nav__menu | ||||||
|  |         if ALPHA | ||||||
|  |             - var NAVIGATION = { "Usage": "/docs/usage", "Reference": "/docs/api" } | ||||||
|  | 
 | ||||||
|         each url, item in NAVIGATION |         each url, item in NAVIGATION | ||||||
|             li.c-nav__menu__item(class=(url == "/") ? "u-hidden-xs" : null) |             li.c-nav__menu__item(class=(url == "/") ? "u-hidden-xs" : null) | ||||||
|                 +a(url)=item |                 +a(url)=item | ||||||
|  |  | ||||||
|  | @ -10,6 +10,14 @@ main.o-main.o-main--sidebar.o-main--aside | ||||||
|             if tag |             if tag | ||||||
|                 +tag=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 |         !=yield | ||||||
| 
 | 
 | ||||||
|     +grid.o-content.u-text |     +grid.o-content.u-text | ||||||
|  |  | ||||||
|  | @ -35,7 +35,10 @@ html(lang="en") | ||||||
|     link(rel="shortcut icon" href="/assets/img/favicon.ico") |     link(rel="shortcut icon" href="/assets/img/favicon.ico") | ||||||
|     link(rel="icon" type="image/x-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") |         link(href="/assets/css/style_red.css?v#{V_CSS}" rel="stylesheet") | ||||||
| 
 | 
 | ||||||
|     else |     else | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue
	
	Block a user