From e56dc9a07521da160c5e693709d93ffc3bbea74a Mon Sep 17 00:00:00 2001 From: Ines Montani Date: Wed, 19 Oct 2016 00:19:42 +0200 Subject: [PATCH] Update website --- website/_harp.json | 48 +- website/_includes/_article.jade | 35 - website/_includes/_footer.jade | 5 - website/_includes/_functions.jade | 57 -- website/_includes/_head.jade | 27 - website/_includes/_mixins.jade | 381 -------- website/_layout.jade | 30 - website/assets/css/_components/_alerts.sass | 35 - website/assets/css/_components/_images.sass | 57 -- website/assets/css/_layout/_footer.sass | 21 - website/assets/img/profile_wolfgang_alt.png | Bin 410210 -> 0 bytes website/blog/_data.json | 241 ----- website/blog/announcement.jade | 10 - .../blog/displacy-dependency-visualizer.jade | 28 - .../blog/eli5-computers-learn-reading.jade | 37 - website/blog/german-model.jade | 214 ----- website/blog/how-spacy-works.jade | 143 --- website/blog/img/anchovies.png | Bin 151222 -> 0 bytes website/blog/img/german.jpg | Bin 211253 -> 0 bytes website/blog/img/german_english_proj.svg | 158 ---- website/blog/img/german_german_nonproj.svg | 308 ------- website/blog/img/german_large.jpg | Bin 295238 -> 0 bytes website/blog/img/german_pseudoproj.svg | 871 ------------------ website/blog/img/german_small.jpg | Bin 74627 -> 0 bytes website/blog/img/german_verb_align.svg | 319 ------- website/blog/img/syntaxnet.jpg | Bin 392062 -> 0 bytes website/blog/img/syntaxnet_large.jpg | Bin 627775 -> 0 bytes website/blog/img/syntaxnet_small.jpg | Bin 120686 -> 0 bytes website/blog/multithreading-with-cython.jade | 157 ---- website/blog/sense2vec-with-spacy.jade | 166 ---- website/blog/syntaxnet-in-context.jade | 55 -- website/demos/_data.json | 26 - website/demos/index.jade | 18 - website/docs/_api-english.jade | 4 - website/docs/_api-token.jade | 4 - website/docs/_quickstart-install.jade | 171 ---- website/docs/index.jade | 15 - website/docs/tutorials/byo-annotations.jade | 22 - website/feed.xml.jade | 30 - website/index.jade | 144 --- 40 files changed, 9 insertions(+), 3828 deletions(-) delete mode 100644 website/_includes/_article.jade delete mode 100644 website/_includes/_head.jade delete mode 100644 website/assets/css/_components/_alerts.sass delete mode 100644 website/assets/css/_components/_images.sass delete mode 100644 website/assets/css/_layout/_footer.sass delete mode 100644 website/assets/img/profile_wolfgang_alt.png delete mode 100644 website/blog/displacy-dependency-visualizer.jade delete mode 100644 website/blog/eli5-computers-learn-reading.jade delete mode 100644 website/blog/german-model.jade delete mode 100644 website/blog/how-spacy-works.jade delete mode 100644 website/blog/img/anchovies.png delete mode 100644 website/blog/img/german.jpg delete mode 100644 website/blog/img/german_english_proj.svg delete mode 100644 website/blog/img/german_german_nonproj.svg delete mode 100644 website/blog/img/german_large.jpg delete mode 100644 website/blog/img/german_pseudoproj.svg delete mode 100644 website/blog/img/german_small.jpg delete mode 100644 website/blog/img/german_verb_align.svg delete mode 100644 website/blog/img/syntaxnet.jpg delete mode 100644 website/blog/img/syntaxnet_large.jpg delete mode 100644 website/blog/img/syntaxnet_small.jpg delete mode 100644 website/blog/multithreading-with-cython.jade delete mode 100644 website/blog/sense2vec-with-spacy.jade delete mode 100644 website/blog/syntaxnet-in-context.jade delete mode 100644 website/demos/_data.json delete mode 100644 website/demos/index.jade delete mode 100644 website/feed.xml.jade diff --git a/website/_harp.json b/website/_harp.json index 0257b58d2..1ceb54023 100644 --- a/website/_harp.json +++ b/website/_harp.json @@ -2,13 +2,16 @@ "globals": { "title": "spaCy.io", "description": "spaCy is a free open-source library featuring state-of-the-art speed and accuracy and a powerful Python API.", - "url": "https://spacy.io", - "email": "contact@spacy.io", - "company": "spaCy.io", - "navigation": { "Docs": "docs", "Demos": "demos", "Blog": "blog" }, - "profiles": { "twitter": "spacy_io", "github": "spacy-io", "reddit": "spacynlp", "medium": "spacy" }, - "google_analytics": "UA-58931649-1", + "SITENAME": "spaCy", + "SLOGAN": "Industrial-strength Natural Language Processing", + "SITE_URL": "https://spacy.io", + "EMAIL": "contact@explosion.ai", + + "COMPANY": "Explosion AI", + "COMPANY_URL": "https://explosion.ai", + "DEMOS_URL": "https://demos.explosion.ai", + "SOCIAL": { "twitter": "spacy_io", "github": "explosion", @@ -22,38 +25,5 @@ "SPACY_VERSION": "0.101.0", "SPACY_STARS": "2300", "GITHUB": { "user": "explosion", "repo": "spacy" } - "spacy_version": "0.101.0", - "spacy_stars": "2100", - "github_settings": { "user": "spacy-io", "repo": "spacy" }, - - "authors" : { - "matt" : { - "name" : "Matthew Honnibal", - "description" : "studied linguistics as an undergrad, and never thought he'd be a programmer. By 2009 he had a PhD in computer science, and in 2014 he left academia to write spaCy. He's from Sydney and lives in Berlin.", - "links": { - "twitter": [ "https://twitter.com/honnibal", "Twitter" ], - "website": [ "https://www.semanticscholar.org/search?q=Matthew%20Honnibal", "Semantic Scholar" ] - } - }, - - "ines": { - "name": "Ines Montani", - "description": "has developed, designed and implemented our interactive demos and the spacy.io website. She has a degree in media, linguistics and communications, and over ten years experience in web development.", - "links": { - "twitter": [ "https://twitter.com/_inesmontani", "Twitter" ], - "codepen": [ "https://codepen.io/ines", "Codepen"], - "github": [ "https://github.com/ines", "GitHub"], - "website": [ "http://ines.io", "Blog" ] - } - }, - - "wolfgang": { - "name": "Wolfgang Seeker", - "description": "is a computational linguist from Germany. He is fascinated with the complexity and variety of human language, and spent his PhD looking for ways to make NLP work well with any kind of language in the world. He joined spaCy to build effective and truly multilingual NLP software.", - "links": { - "website": [ "https://www.semanticscholar.org/search?q=Wolfgang%20Seeker", "Semantic Scholar" ] - } - } - } } } diff --git a/website/_includes/_article.jade b/website/_includes/_article.jade deleted file mode 100644 index 08d7c9e04..000000000 --- a/website/_includes/_article.jade +++ /dev/null @@ -1,35 +0,0 @@ -include ../_includes/_mixins - -//- Article -//- ============================================================================ - -article.article(id=current.source) - - header.article-header - +h2.article-title=title - .article-meta - if author - | by #[a.link(href=(authors[author].url || url) target='_blank')=authors[author].name] on   - | #[+date(date)] - - .article-body!=yield - - footer.article-footer - - +grid('padding', 'align-right', 'valign-center') - if hide_social != true - +tweet(title) - - if links - for link, index in links - div: +button('primary', 'small', index.toLowerCase())(href=link target='_blank') - +icon(index.toLowerCase(), 'medium', 'secondary') - | Discussion on #{index} - - if author - +divider - - !=partial('_profile', { label: 'About the Author', style: 'alt' }) - -!=partial('_newsletter', { divider: 'both' }) -!=partial('_latest-posts', { max: 2, _section: _section } ) diff --git a/website/_includes/_footer.jade b/website/_includes/_footer.jade index 5a97d4d79..bd7688bfb 100644 --- a/website/_includes/_footer.jade +++ b/website/_includes/_footer.jade @@ -7,13 +7,8 @@ include _mixins footer.o-footer.o-inline-list.u-pattern.u-text-center.u-text-label.u-text-strong span © #{new Date().getFullYear()} #[+a(COMPANY_URL, true)=COMPANY] -<<<<<<< HEAD +a(COMPANY_URL + "/legal", true) Legal / Imprint a(href="mailto:#{EMAIL}") #[+icon("mail", 16)] -======= -footer.footer - span © #{new Date().getFullYear()} #{company} ->>>>>>> v1.0.0-rc1 +a("https://twitter.com/" + SOCIAL.twitter)(aria-label="Twitter") +icon("twitter", 20) diff --git a/website/_includes/_functions.jade b/website/_includes/_functions.jade index cef2a90b9..a191b330d 100644 --- a/website/_includes/_functions.jade +++ b/website/_includes/_functions.jade @@ -5,64 +5,7 @@ //- Add prefixes to items of an array (for modifier CSS classes) - function prefixArgs(array, prefix) { -<<<<<<< HEAD - return array.map(function(arg) { - return prefix + '--' + arg; - }).join(' '); -======= -- for(var i = 0; i < array.length; i++) { -- array[i] = prefix + array[i]; -- } -- return array.join(' '); -- } - - -//- Convert date to human readable and timestamp format - input - [string] date in the format YYYY-MM-DD - -- function convertDate(input) { -- var dates = []; -- var months = [ 'January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December' ]; -- var date = new Date(input); -- dates.full = months[date.getMonth()] + ' ' + date.getDate() + ', ' + date.getFullYear(); -- dates.timestamp = JSON.parse(JSON.stringify(date)); -- return dates; -- } - - -//- Convert date to valid RSS pubDate - input - [string] date in the format YYYY-MM-DD - -- function convertPubDate(input) { -- var date = new Date(input); -- var pieces = date.toString().split(' '); -- var offsetTime = pieces[5].match(/[-+]\d{4}/); -- var offset = (offsetTime) ? offsetTime : pieces[5]; -- var parts = [ pieces[0] + ',', pieces[2], pieces[1], pieces[3], pieces[4], offset ]; -- return parts.join(' '); -- } - - -//- Compile scrset attribute for hero images - image - [object] article image object from _data.json - path - [string] relative path to image folder - -- function getScrset(image, path) { -- var scrset = path + image.file + ' ' + image_sizes.medium + 'w'; -- if(image.file_small) scrset += ', ' + path + image.file_small + ' ' + image_sizes.small + 'w'; -- if(image.file_large) scrset += ', ' + path + image.file_large + ' ' + image_sizes.large + 'w'; -- return scrset; -- } - - -//- Get meta image - -- function getMetaImage() { -- if(current.path[0] == 'blog' && image && image.file) { -- return url + '/blog/img/' + (image.file_small || image.file); -- } -- else { -- return url + '/assets/img/social.png'; -- } ->>>>>>> v1.0.0-rc1 - } diff --git a/website/_includes/_head.jade b/website/_includes/_head.jade deleted file mode 100644 index 5d36dc2f7..000000000 --- a/website/_includes/_head.jade +++ /dev/null @@ -1,27 +0,0 @@ -include _mixins - -//- Head -//- ============================================================================ - -head - title=getPageTitle() - - meta(charset='utf-8') - meta(name="viewport" content="width=device-width, initial-scale=1.0") - meta(name='referrer' content='always') - meta(name='description' content=description) - - meta(property='og:type' content='website') - meta(property='og:site_name' content=sitename) - meta(property='og:url' content=getCurrentUrl()) - meta(property='og:title' content=title) - meta(property='og:description' content=description) - meta(property='og:image' content=getMetaImage()) - - meta(name='twitter:card' content='summary_large_image') - meta(name='twitter:site' content='@' + profiles.twitter) - meta(name='twitter:title' content=title) - meta(name='twitter:description' content=description) - meta(name='twitter:image' content=getMetaImage()) - - link(rel='icon' type='image/x-icon' href='/assets/img/favicon.ico') diff --git a/website/_includes/_mixins.jade b/website/_includes/_mixins.jade index f02e5d9e0..04faf8993 100644 --- a/website/_includes/_mixins.jade +++ b/website/_includes/_mixins.jade @@ -1,389 +1,8 @@ -<<<<<<< HEAD //- ---------------------------------- //- đź’« INCLUDES > MIXINS //- ---------------------------------- include _functions -======= -include _functions - -//- Mixins -//- ============================================================================ - -//- Sections for content pages - id - [string] id, can be headline id as it's being prefixed (optional) - block - section content (block and inline elements) - -mixin section(id) - section.section(id=(id) ? 'section-' + id : '')&attributes(attributes) - block - - -//- Flexbox grid to align children elements - ...style - [strings] flexbox CSS classes without prefix (optional) - block - container content (block and inline elements) - -mixin grid(...style) - .grid(class=prefixArgs(style, 'grid--'))&attributes(attributes) - block - -mixin grid-col(...style) - .grid-col(class=prefixArgs(style, 'grid-col--'))&attributes(attributes) - block - - -//- Aside - headline - [string] Headline of aside (optional) - block - aside content (inline elements) - -mixin aside(headline) - span.aside(data-label=headline)&attributes(attributes) - span.aside-body - block - - -//- Paragraphs - block - paragraph content (inline elements) - -mixin lead - p.text-lead&attributes(attributes) - block - - -//- Various text styles - block - text (inline elements) - -mixin example - p.text-example&attributes(attributes) - block - -mixin source - span.text-source&attributes(attributes) - block - -mixin label(...style) - span(class=(style != '') ? prefixArgs(style, 'label-') : 'label')&attributes(attributes) - block - - -//- Headings with optional permalinks - id - [string] unique id (optional, no permalink without id) - source - [string] link for source button (optional) - block - headline text (inline elements) - -mixin headline(level, id, source) - if level == 2 - +h2(id, source) - block - - else if level == 3 - +h3(id, source) - block - - else if level == 4 - +h4(id, source) - block - - else if level == 5 - +h5(id, source) - block - - else - +h6(id, source) - block - -mixin h1(id, source) - h1(id=id)&attributes(attributes) - +permalink(id, source) - block - -mixin h2(id, source) - h2(id=id)&attributes(attributes) - +permalink(id, source) - block - -mixin h3(id, source) - h3(id=id)&attributes(attributes) - +permalink(id, source) - block - -mixin h4(id, source) - h4(id=id)&attributes(attributes) - +permalink(id, source) - block - -mixin h5(id, source) - h5(id=id)&attributes(attributes) - +permalink(id, source) - block - -mixin h6(id, source) - h6(id=id)&attributes(attributes) - +permalink(id, source) - block - -mixin permalink(id, source) - if id - a.permalink(href='#' + id) - block - - else - block - - if source - +button('secondary', 'small', 'source')(href=source target='_blank') Source - - -//- Button - element - [string] specifies HTML element, 'button' or 'link' - ...style - [strings] button CSS classes without prefix (optional) - block - button text (inline elements) - -mixin button(type, ...style) - - var classname = 'button-' + type + ' ' + ((style) ? prefixArgs(style, 'button--') : '') - - a.button(class=classname)&attributes(attributes) - block - -mixin form-button(type, ...style) - - var classname = 'button-' + type + ' ' + ((style) ? prefixArgs(style, 'button--') : '') - button(class=classname)&attributes(attributes) - block - - -//- Input - placeholder - [string] placeholder for input field (optional) - value - [string] value of input field (optional) - -mixin input(placeholder, value) - input.input(placeholder=placeholder value=value)&attributes(attributes) - - -//- Icon - name - [string] icon name, refers to CSS classes - size - [string] 'medium' or 'large' (optional) - type - [string] 'button' (optional) - block - description, if as a text node to the icon element it prevents line - breaks between icon and text (inline elements) - -mixin icon(type, ...style) - span(class='icon-' + type + ' ' + prefixArgs(style, 'icon--') aria-hidden="true")&attributes(attributes) - block - - -//- Image for illustration purposes - file - [string] file name (in /img) - alt - [string] descriptive alt text (optional) - caption - [string] image caption (optional) - -mixin image(file, alt, caption, size) - figure.image-container&attributes(attributes) - img(src='img/' + file alt=alt class=(size) ? 'image--' + size : '') - - if caption - figcaption.text-caption=caption - - block - - -//- Illustrated code view - title - [string] title of window - -mixin code-demo(title) - .x-terminal&attributes(attributes) - .x-terminal-icons: span - .x-terminal-title=title - +code.x-terminal-code - block - - -//- Data table - head - [array] column headings (optional, without headings no table - head is displayed) - ...style - [strings] table CSS classes without prefix (optional) - block - only +row (tr) - -mixin table(head, ...style) - table.table(class=prefixArgs(style, 'table--'))&attributes(attributes) - - if head - tr.table-row - each column in head - th.table-head-cell=column - - block - - -//- Data table row - block - only +cell (td) - -mixin row(...style) - tr.table-row(class=prefixArgs(style, 'table-cell--'))&attributes(attributes) - block - - -//- Data table cell - block - table cell content (inline elements) - -mixin cell(...style) - td.table-cell(class=prefixArgs(style, 'table-cell--'))&attributes(attributes) - block - - -//- General list (ordered and unordered) - type - [string] 'numbers', 'letters', 'roman' (optional) - start - [integer] starting point of list (1 = list starts at 1 or A) - block - only +item (li) - -mixin list(type, start) - if type - ol.list(class='list--' + type style=(start === 0 || start) ? 'counter-reset: li ' + (start - 1) : '')&attributes(attributes) - block - - else - ul.list.list--bullets&attributes(attributes) - block - - -//- List item - block - item text (inline elements) - -mixin item - li.list-item&attributes(attributes) - block - - -//- Blockquote - source - [string] quote source / author (optional) - link - [string] link to quote source (only with source, optional) - block - quote text (inline elements) - -mixin quote(source, link) - blockquote.quote&attributes(attributes) - p.quote-text - block - - if source && link - | #[a.quote-source(href=link target='_blank')=source] - - else if source && !link - .quote-source !{source} - - -//- Pullquotes with optional 'tweet this' function - tweet - [string] text to be tweeted (optional) - block - pullquote text (inline elements, only shown if no tweet text) - -mixin pullquote(tweet) - blockquote.quote&attributes(attributes) - - p.quote-text-strong - if tweet - | !{tweet} #[a.quote-source(href=twitterShareUrl(current.path, tweet) target='_blank') Tweet this] - - else - block - - -//- Code block - use as +code(args). to preserve whitespace and prevent code interprettion - language - [string] language for syntax highlighting (optional, default: - 'python', see Prism for options: http://prismjs.com) - label - [string] code block headline (optional) - block - code text (inline elements) - - -mixin code(language, label) - pre.code-block(class='lang-' + (language || default_syntax) data-label=label)&attributes(attributes) - code.code-inline - block - - -//- Infobox for notes and alerts - label - [string] infobox headline (optional) - block - infobox text (inline and block elements) - -mixin infobox(label) - .box.box--info(data-label=label)&attributes(attributes) - p.box-body - block - - -//- Alerts for notes and updates - -mixin alert(button) - .alert&attributes(attributes) - span - block - - if button - +form-button('primary', 'small')(onclick='this.parentNode.parentNode.removeChild(this.parentNode);')=button - - else - button.alert-close(onclick='this.parentNode.parentNode.removeChild(this.parentNode);') - - - -//- Embeds - border - [boolean] add border to embed container - caption - [string] embed caption - block - embed content (inline and block elements) - -mixin embed(border, caption) - figure.embed(class=(border) ? 'embed--border' : '')&attributes(attributes) - block - - if caption - figcaption.embed-caption=caption - - -//- displaCy - filename - [string] name of file in displacy folder (no .html) - caption - [string] caption (optional) - height - [integer] iframe height in px (optional) - -mixin displacy(filename, caption, height) - +embed(true, caption).embed--displacy - iframe(src='/blog/displacy/' + filename height=height) - - -//- Logo, imports SVG - size - [string] 'tiny', 'small', 'regular' or 'large' - -mixin logo(size) - !=partial('/_includes/_logo', { logo_size: size }) - - -//-