This is an automated email from the ASF dual-hosted git repository. gerben pushed a commit to branch asf-site in repository https://gitbox.apache.org/repos/asf/incubator-annotator-website.git
commit ecde1b3cc833d0652ee865171ea5c3ba2c4b37e5 Author: Gerben <[email protected]> AuthorDate: Sun May 9 10:55:48 2021 +0200 Dedupe & factor out header&footer from templates --- src/_includes/page_footer.hbs | 35 +++++++++++++++++ src/_includes/page_header.hbs | 16 ++++++++ src/_layouts/default.hbs | 70 ++------------------------------- src/_layouts/docs.hbs | 18 +++++++++ src/docs/getting-started.md | 2 +- src/docs/index.md | 2 +- src/index.html | 91 ++----------------------------------------- 7 files changed, 78 insertions(+), 156 deletions(-) diff --git a/src/_includes/page_footer.hbs b/src/_includes/page_footer.hbs new file mode 100644 index 0000000..7cd2ea5 --- /dev/null +++ b/src/_includes/page_footer.hbs @@ -0,0 +1,35 @@ + <footer class="ui bottom attached segment"> + <div class="ui container"> + <div class="ui equal height divided stackable grid"> + <div class="four wide column"> + <a class="ui left floated medium image" href="https://apache.org/" target="_blank"> + <img src="https://incubator.apache.org/images/incubator_feather_egg_logo_sm.png" alt="logo of the Apache Incubator" /> + </a> + <p> + <em>Copyright © 2016-2018 The Apache Software Foundation, Licensed under + the <a href="https://www.apache.org/licenses/LICENSE-2.0" rel="license external">Apache License, Version 2.0</a>. + | + <a rel="external" href="https://www.apache.org/foundation/policies/privacy">Privacy Policy</a> + </em> + </p> + </div> + <div class="nine wide column"> + <p> + <em>Apache Annotator is an effort undergoing incubation at <a target="_blank" href="https://apache.org/">The Apache Software Foundation (ASF)</a> sponsored by the Apache Incubator PMC. Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects. While incubation status is not necessarily a reflection of the [...] + <p><em>Apache®, the names of Apache projects, and the feather logo are either <a rel="external" href="https://www.apache.org/foundation/marks/list/">registered trademarks or trademarks</a> of the Apache Software Foundation in the United States and/or other countries.</em></p> + </div> + <div class="three wide column"> + <h4 class="header">The <abbr title="Apache Software Foundation">ASF</abbr></h4> + <div class="ui link list"> + <a class="item" rel="external" href="https://incubator.apache.org/">Apache Incubator</a> + <a class="item" rel="external" href="https://www.apache.org/">About the ASF</a> + <a class="item" rel="external" href="https://www.apache.org/events/current-event">Events</a> + <a class="item" rel="external" href="https://www.apache.org/foundation/thanks.html">Thanks</a> + <a class="item" rel="external" href="https://www.apache.org/foundation/sponsorship.html">Become a Sponsor</a> + <a class="item" rel="external" href="https://www.apache.org/security/">Security</a> + <a class="item" rel="external" href="https://www.apache.org/licenses/">License</a> + </div> + </div> + </div> + </div> + </footer> diff --git a/src/_includes/page_header.hbs b/src/_includes/page_header.hbs new file mode 100644 index 0000000..efbe186 --- /dev/null +++ b/src/_includes/page_header.hbs @@ -0,0 +1,16 @@ + <div class="ui borderless stackable top attached main menu"> + <div class="ui container"> + <a class="item" href="/" style="color: rgba(0,0,0,.87);"> + <img class="ui small image" src="/images/annotator-logo.svg" alt="Apache Annotator (incubating)" /> + </a> + + <div class="right menu"> + <a class="item" href="/demo/"><span class="ui positive button">Demo!</span></a> + <a class="item" rel="external" href="https://www.npmjs.com/package/apache-annotator">NPM</a> + <a class="item" rel="external" href="https://github.com/apache?q=annotator#org-repositories">Code</a> + <a class="item" rel="external" href="https://github.com/apache/incubator-annotator/issues">Issues</a> + <a class="{{#if isDocs}}active {{/if}}item" href="/docs/">Docs</a> + <a class="item" rel="external" href="https://mail-archives.apache.org/mod_mbox/incubator-annotator-dev/">Mailing List</a> + </div> + </div> + </div> diff --git a/src/_layouts/default.hbs b/src/_layouts/default.hbs index 2906275..c139d2e 100644 --- a/src/_layouts/default.hbs +++ b/src/_layouts/default.hbs @@ -26,74 +26,10 @@ </head> <body> - <div class="ui borderless stackable top attached main menu"> - <div class="ui container"> - <a class="item" href="/" style="color: rgba(0,0,0,.87);"> - <img class="ui small image" src="/images/annotator-logo.svg" alt="Apache Annotator (incubating)" /> - </a> - - <div class="right menu"> - <a class="item" href="/demo"><span class="ui positive button">Demo!</span></a> - <a class="item" rel="external" href="https://www.npmjs.com/package/apache-annotator">NPM</a> - <a class="item" rel="external" href="https://github.com/apache?q=annotator#org-repositories">Code</a> - <a class="item" rel="external" href="https://github.com/apache/incubator-annotator/issues">Issues</a> - <span class="active item"><strong>Docs</strong></span> - <a class="item" rel="external" href="https://mail-archives.apache.org/mod_mbox/incubator-annotator-dev/">Mailing List</a> - </div> - </div> - </div> - + {{> page_header}} <div class="ui basic segment container"> - <div class="ui grid"> - <div class="three wide column"> - <div class="ui vertical secondary menu"> - {{#each collections.all}} - {{#if (not-eq this.url '/')}} - <div class="{{#if (eq ../page.url this.url)}}active {{/if}}item"><a href="{{this.url}}">{{this.data.title}}</a></div> - {{/if}} - {{/each}} - </div> - </div> - <div class="nine wide column"> - {{{content}}} - </div> - </div> + {{{content}}} </div> - - <footer class="ui bottom attached segment"> - <div class="ui container"> - <div class="ui equal height divided stackable grid"> - <div class="four wide column"> - <a class="ui left floated medium image" href="https://apache.org/" target="_blank"> - <img src="https://incubator.apache.org/images/incubator_feather_egg_logo_sm.png" alt="logo of the Apache Incubator" /> - </a> - <p> - <em>Copyright © 2016-2018 The Apache Software Foundation, Licensed under - the <a href="https://www.apache.org/licenses/LICENSE-2.0" rel="license external">Apache License, Version 2.0</a>. - | - <a rel="external" href="https://www.apache.org/foundation/policies/privacy">Privacy Policy</a> - </em> - </p> - </div> - <div class="nine wide column"> - <p> - <em>Apache Annotator is an effort undergoing incubation at <a target="_blank" href="https://apache.org/">The Apache Software Foundation (ASF)</a> sponsored by the Apache Incubator PMC. Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects. While incubation status is not necessarily a reflection of the [...] - <p><em>Apache®, the names of Apache projects, and the feather logo are either <a rel="external" href="https://www.apache.org/foundation/marks/list/">registered trademarks or trademarks</a> of the Apache Software Foundation in the United States and/or other countries.</em></p> - </div> - <div class="three wide column"> - <h4 class="header">The <abbr title="Apache Software Foundation">ASF</abbr></h4> - <div class="ui link list"> - <a class="item" rel="external" href="https://incubator.apache.org/">Apache Incubator</a> - <a class="item" rel="external" href="https://www.apache.org/">About the ASF</a> - <a class="item" rel="external" href="https://www.apache.org/events/current-event">Events</a> - <a class="item" rel="external" href="https://www.apache.org/foundation/thanks.html">Thanks</a> - <a class="item" rel="external" href="https://www.apache.org/foundation/sponsorship.html">Become a Sponsor</a> - <a class="item" rel="external" href="https://www.apache.org/security/">Security</a> - <a class="item" rel="external" href="https://www.apache.org/licenses/">License</a> - </div> - </div> - </div> - </div> - </footer> + {{> page_footer}} </body> </html> diff --git a/src/_layouts/docs.hbs b/src/_layouts/docs.hbs new file mode 100644 index 0000000..0aacde4 --- /dev/null +++ b/src/_layouts/docs.hbs @@ -0,0 +1,18 @@ +--- +layout: default +isDocs: true +--- + <div class="ui grid"> + <div class="three wide column"> + <div class="ui vertical secondary menu"> + {{#each collections.all}} + {{#if (not-eq this.url '/')}} + <div class="{{#if (eq ../page.url this.url)}}active {{/if}}item"><a href="{{this.url}}">{{this.data.title}}</a></div> + {{/if}} + {{/each}} + </div> + </div> + <div class="nine wide column"> + {{{content}}} + </div> + </div> diff --git a/src/docs/getting-started.md b/src/docs/getting-started.md index 72e6aba..3643292 100644 --- a/src/docs/getting-started.md +++ b/src/docs/getting-started.md @@ -1,6 +1,6 @@ --- title: Getting Started -layout: default +layout: docs --- Please checkout the [demo](/demo/) for now, but we'll explain it here soon. diff --git a/src/docs/index.md b/src/docs/index.md index 131c2c1..528b88f 100644 --- a/src/docs/index.md +++ b/src/docs/index.md @@ -1,6 +1,6 @@ --- title: Documentation -layout: default +layout: docs --- We're working on some initial documentation for getting started with Apache diff --git a/src/index.html b/src/index.html index 53bfa65..70a6bd0 100644 --- a/src/index.html +++ b/src/index.html @@ -1,49 +1,6 @@ -<!DOCTYPE html> -<html prefix="og: http://ogp.me/ns#"> - <head> - <meta charset="utf-8"> - <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> - <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1"> - <title>Apache Annotator (incubating)</title> - - <meta property="og:title" content="Apache Annotator" /> - <meta property="og:type" content="website" /> - <meta property="og:url" content="https://annotator.apache.org/" /> - <meta property="og:image:url" content="https://annotator.apache.org/images/annotator-logo.svg" /> - <meta property="og:image:alt" content="Apache Annotator (incubating) logo" /> - - <link rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon.png"> - <link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32.png"> - <link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16.png"> - <link rel="manifest" href="/site.webmanifest"> - <link rel="mask-icon" href="/images/safari-pinned-tab.svg" color="#5bbad5"> - <meta name="msapplication-TileColor" content="#da532c"> - <meta name="theme-color" content="#ffffff"> - - <link rel="alternate" title="DOAP" href="doap.rdf" type="application/rdf+xml" /> - - <link rel="stylesheet" href="//semantic-ui.com/dist/semantic.min.css" /> - </head> - - <body> - <div class="ui borderless stackable top attached main menu"> - <div class="ui container"> - <a class="item" href="/" style="color: rgba(0,0,0,.87);"> - <img class="ui small image" src="images/annotator-logo.svg" alt="Apache Annotator (incubating)" /> - </a> - - <div class="right menu"> - <a class="item" href="demo/"><span class="ui positive button">Demo!</span></a> - <a class="item" rel="external" href="https://www.npmjs.com/package/apache-annotator">NPM</a> - <a class="item" rel="external" href="https://github.com/apache?q=annotator#org-repositories">Code</a> - <a class="item" rel="external" href="https://github.com/apache/incubator-annotator/issues">Issues</a> - <a class="item" href="docs">Docs</a> - <a class="item" rel="external" href="https://mail-archives.apache.org/mod_mbox/incubator-annotator-dev/">Mailing List</a> - </div> - </div> - </div> - - <div class="ui basic segment container"> +--- +layout: default +--- <div class="ui divided grid"> <div class="ten wide column"> <h3> @@ -183,44 +140,4 @@ </div> </div> </div> - </div> - - <footer class="ui bottom attached segment"> - <div class="ui container"> - <div class="ui equal height divided stackable grid"> - <div class="four wide column"> - <a class="ui left floated medium image" href="https://apache.org/" target="_blank"> - <img src="https://incubator.apache.org/images/incubator_feather_egg_logo_sm.png" alt="logo of the Apache Incubator" /> - </a> - <p> - <em>Copyright © 2016-2018 The Apache Software Foundation, Licensed under - the <a href="https://www.apache.org/licenses/LICENSE-2.0" rel="license external">Apache License, Version 2.0</a>. - | - <a rel="external" href="https://www.apache.org/foundation/policies/privacy">Privacy Policy</a> - </em> - </p> - </div> - <div class="nine wide column"> - <p> - <em>Apache Annotator is an effort undergoing incubation at <a target="_blank" href="https://apache.org/">The Apache Software Foundation (ASF)</a> sponsored by the Apache Incubator PMC. Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects. While incubation status is not necessarily a reflection of the [...] - <p><em>Apache®, the names of Apache projects, and the feather logo are either <a rel="external" href="https://www.apache.org/foundation/marks/list/">registered trademarks or trademarks</a> of the Apache Software Foundation in the United States and/or other countries.</em></p> - </div> - <div class="three wide column"> - <h4 class="header">The <abbr title="Apache Software Foundation">ASF</abbr></h4> - <div class="ui link list"> - <a class="item" rel="external" href="https://incubator.apache.org/">Apache Incubator</a> - <a class="item" rel="external" href="https://www.apache.org/">About the ASF</a> - <a class="item" rel="external" href="https://www.apache.org/events/current-event">Events</a> - <a class="item" rel="external" href="https://www.apache.org/foundation/thanks.html">Thanks</a> - <a class="item" rel="external" href="https://www.apache.org/foundation/sponsorship.html">Become a Sponsor</a> - <a class="item" rel="external" href="https://www.apache.org/security/">Security</a> - <a class="item" rel="external" href="https://www.apache.org/licenses/">License</a> - </div> - </div> - </div> - </div> - </footer> - - <script async defer src="index.js"></script> - </body> -</html> + <script async defer src="index.js"></script>
