diff --git a/.gitignore b/.gitignore index a48cf0de7af6613887a8f33ce5957001234ac817..d6ac840735cc545a4924ad2097d29a76c4098da8 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ +node_modules public +resources diff --git a/assets/css/_fonts.scss b/assets/css/_fonts.scss new file mode 100644 index 0000000000000000000000000000000000000000..78028140854375d9d36cc1270e316a310f65c7a9 --- /dev/null +++ b/assets/css/_fonts.scss @@ -0,0 +1,35 @@ +@font-face { + font-family: 'Quicksand'; + font-style: normal; + font-weight: 400; + src: local(''), + url('../fonts/quicksand-v21-latin-regular.woff2') format('woff2'), + url('../fonts/quicksand-v21-latin-regular.woff') format('woff'); +} + +@font-face { + font-family: 'Quicksand'; + font-style: normal; + font-weight: 700; + src: local(''), + url('../fonts/quicksand-v21-latin-700.woff2') format('woff2'), + url('../fonts/quicksand-v21-latin-700.woff') format('woff'); +} + +@font-face { + font-family: 'Open Sans'; + font-style: normal; + font-weight: 400; + src: local('Open Sans Regular'), local('OpenSans-Regular'), + url('../fonts/open-sans-v17-latin-regular.woff2') format('woff2'), + url('../fonts/open-sans-v17-latin-regular.woff') format('woff'); +} + +@font-face { + font-family: 'Open Sans'; + font-style: normal; + font-weight: 700; + src: local('Open Sans Bold'), local('OpenSans-Bold'), + url('../fonts/open-sans-v17-latin-700.woff2') format('woff2'), + url('../fonts/open-sans-v17-latin-700.woff') format('woff'); +} diff --git a/assets/css/_variables.scss b/assets/css/_variables.scss new file mode 100644 index 0000000000000000000000000000000000000000..28826c7a936266c47575cd29b5a0175c8cd7116a --- /dev/null +++ b/assets/css/_variables.scss @@ -0,0 +1,9 @@ +$font-family-common: 'Quicksand', sans-serif; +$font-family-content: 'Open Sans', sans-serif; +$main-color: #fe8e04; +$secondary-color: #879bd3; +$base-color: #31363b; +$font-color: #fff; +$font-color-secondary: #000; +$link-color: #879bd3; +$max-width: 960px; diff --git a/assets/css/components/_content.scss b/assets/css/components/_content.scss new file mode 100644 index 0000000000000000000000000000000000000000..722a79a1e66950b73e3eb32e75ab7efc7c55124c --- /dev/null +++ b/assets/css/components/_content.scss @@ -0,0 +1,30 @@ +body { + background-image: url(/images/background.jpg); + background-repeat: no-repeat; + background-attachment: fixed; + background-size: 100%; + + main { + margin-top: 500px; + + h2 { + max-width: $max-width; + margin: 0 auto; + + &:not(:first-of-type) { + margin-top: 50px; + } + } + + .wrapper { + box-shadow: -2px -3px 10px $base-color, 2px -3px 10px $base-color; + background-color: $base-color; + padding-bottom: 50px; + } + } +} + +.wrapper p, +.wrapper .line-block { + padding: 10px 20px; +} diff --git a/assets/css/components/_footer.scss b/assets/css/components/_footer.scss new file mode 100644 index 0000000000000000000000000000000000000000..0baa4560a07f572a1746da55d4205814c7edf34e --- /dev/null +++ b/assets/css/components/_footer.scss @@ -0,0 +1,51 @@ +footer { + color: $font-color-secondary; + + a { + color: $font-color-secondary; + } + + ul { + list-style-type: none; + bottom: 10px; + right: 10px; + text-align: right; + padding: 60px 20px 30px 20px; + margin: 0; + } + + .wrapper { + background-color: $secondary-color; + margin: 0 auto; + } +} + +div.attribution { + display: none; + position: fixed; + background-color: $base-color; + color: $font-color; + font-weight: bold; + border-radius: 10px; + border: 2px solid $main-color; + bottom: 10px; + right: 35px; + padding: 10px; + +} + +a:hover.attribution-toggle+div.attribution { + display: block; +} + +a.attribution-toggle { + position: fixed; + bottom: 10px; + right: 10px; +} + +@media screen and (max-width: 980px) { + a.attribution-toggle { + display: none; + } +} diff --git a/assets/css/components/_header.scss b/assets/css/components/_header.scss new file mode 100644 index 0000000000000000000000000000000000000000..cf782ba625fae4596d1fd7646919a14f92ff45ef --- /dev/null +++ b/assets/css/components/_header.scss @@ -0,0 +1,49 @@ +header { + height: 80px; + background-color: $base-color; + position: fixed; + width: 100%; + box-shadow: 0px 3px 10px $base-color; + + #logo { + float: left; + margin-top: 10px; + + h1 { + margin-left: 55px; + margin-top: 13px; + font-size: 24px; + } + + img { + float: left; + height: 48px; + width: 48px; + } + } + + nav { + float: right; + margin-top: 18px; + + ul { + list-style-type: none; + padding-top: 10px; + + li { + float: left; + padding: 0 10px; + border-right: 1px solid #bbb; + + &:last-child { + border-right: none; + } + } + } + } + + a { + color: $font-color; + font-weight: bold; + } +} diff --git a/assets/css/main.scss b/assets/css/main.scss new file mode 100644 index 0000000000000000000000000000000000000000..c3df82283b2be8bd9dc0d1bbc205acfcb647ca7a --- /dev/null +++ b/assets/css/main.scss @@ -0,0 +1,84 @@ +@import "fonts"; +@import "variables"; +@import "components/header"; +@import "components/content"; +@import "components/footer"; + +html, +body, +img, +div, +ul, +li, +span, +p, +h1, +h2, +h3, +h4, +h5, +form, +dl, +dt, +dd, +button { + margin: 0; + padding: 0; + border: 0; +} + +html, +body { + overflow-x: hidden; +} + +body { + background-color: $base-color; + color: $font-color; + font-family: $font-family-content; + font-size: 15px; + margin: 0; +} + +h1, +h2, +h3, +h4, +h5, +nav, +footer a { + font-family: $font-family-common; +} + +h2 { + background-color: $main-color; + color: $font-color-secondary; + font-size: 1.2em; + margin-top: 0; + padding: 20px; +} + +a { + color: $link-color; + text-decoration: none; +} + +table { + border-collapse: collapse; +} + +table, +th, +td { + border: 1px solid #666; + padding: 5px; +} + +th { + text-align: left; +} + +.wrapper { + max-width: $max-width; + margin: 0 auto; +} diff --git a/config.toml b/config.toml index 828dabc67a0297e215f0f5e95ab47aa5c1f38edd..304fced15f2ad7a0e179075b15fe05fa43468694 100644 --- a/config.toml +++ b/config.toml @@ -4,3 +4,6 @@ title = "OpenBuildingMap" [params] author = "Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ" description = "A building-focused window to OpenStreetMap" + +[markup.goldmark.renderer] + unsafe= true diff --git a/content/contact.md b/content/contact.md new file mode 100644 index 0000000000000000000000000000000000000000..69fb13e2514d3bf5ba98bb074c4269c6b9824a17 --- /dev/null +++ b/content/contact.md @@ -0,0 +1,21 @@ +--- +title: "Contact" +date: 2021-04-21T00:00:00Z +draft: false +--- + +## Contact + +Email: contact@openbuildingmap.org\ +Fediverse: [@openbuildingmap](https://en.osm.towm/@openbuildingmap) + +## Imprint & V.i.S.d.P. + +Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ + +Dr. Danijel Schorlemmer\ +Helmholtzstraße 6\ +14467 Potsdam + +Phone: +49 331 288-1207\ +Email: danijel.schorlemmer@gfz-potsdam.de diff --git a/content/copyright.md b/content/copyright.md new file mode 100644 index 0000000000000000000000000000000000000000..ba91b0b6e195e08094eec46755726d3a430e3ea3 --- /dev/null +++ b/content/copyright.md @@ -0,0 +1,17 @@ +--- +title: "Copyright" +date: 2021-04-21T00:00:00Z +draft: false +--- + +## Copyright + +All content, unless otherwise noted, is copyrighted by: + +© [Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ](https://www.gfz-potsdam.de/en/), 2021. + +Map data can be used under the terms of the [Open Data Commons Open Database License - ODbL](https://opendatacommons.org/licenses/odbl/index.html). + +Please attribute any map or data as: + +Data: © [OpenStreetMap](https://openstreetmap.org) © [OpenBuildingMap](http://openbuildingmap.org) diff --git a/content/privacy.md b/content/privacy.md new file mode 100644 index 0000000000000000000000000000000000000000..e0630052cdadaccd626dd7dcabfe5baf7b78b239 --- /dev/null +++ b/content/privacy.md @@ -0,0 +1,9 @@ +--- +title: "Privacy" +date: 2021-04-21T00:00:00Z +draft: false +--- + +## Privacy + +We do not track you! This website does not set cookies. There are no libraries, media, or web fonts hosted by third parties, and you won't find any social networking buttons. It has no analytics and all server logs contain only anonymized IP addresses by default. diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index eb2b2f1c2385b2735b67ef12104d566628210f69..6d9294a14bf2862fc52504279cd1615bee4f6f6a 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -5,5 +5,6 @@ {{ block "header" . }}{{ partial "header" . }}{{ end }} {{ block "main" . }}{{ end }} + {{ block "footer" . }}{{ partial "footer" . }}{{ end }} diff --git a/layouts/_default/index.html b/layouts/_default/index.html index 032cc7e46857f4bd30534afede84b320f02932eb..c090d95d7bc6c96ac459e7d1f7e15dc97c09bf76 100644 --- a/layouts/_default/index.html +++ b/layouts/_default/index.html @@ -1,5 +1,7 @@ {{ define "main" }}
- {{ .Content }} +
+ {{ .Content }} +
{{ end }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html new file mode 100644 index 0000000000000000000000000000000000000000..be619adcbf5840ed5fe83484371bd0fccf218fd9 --- /dev/null +++ b/layouts/_default/single.html @@ -0,0 +1,7 @@ +{{ define "main" }} +
+
+ {{ .Content }} +
+
+{{ end }} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000000000000000000000000000000000000..fdcbae2290ae238457d4a03186ec615b76c6207b --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,16 @@ + + + +
+

Photo by Ajith Kumar

+
diff --git a/layouts/partials/head.html b/layouts/partials/head.html index fa0cf45ae10dcc1ee48cbce5c9003fc3b48761ec..76e5ca34e39d55e224e929feb5c2614926b74ecb 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -12,4 +12,6 @@ + {{ $style := resources.Get "css/main.scss" | toCSS | minify | fingerprint }} + diff --git a/src/css/styles.scss b/src/css/styles.scss new file mode 100644 index 0000000000000000000000000000000000000000..c0544e418e74674aa9b05e63af48e7774f61231b --- /dev/null +++ b/src/css/styles.scss @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2021: + * Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ + + * This program is free software: you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation, either version 3 of the License, or (at + * your option) any later version. + + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero + * General Public License for more details. + + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see http://www.gnu.org/licenses/. + */ + +$background-color: black; +$color: white; + +body { + color: $color; + background-color: $background-color; +} diff --git a/src/js/index.js b/src/js/index.js new file mode 100644 index 0000000000000000000000000000000000000000..766a9749af29f9522774679bf162966942bd983d --- /dev/null +++ b/src/js/index.js @@ -0,0 +1,23 @@ +/** + * @fileOverview The entry point to the app + * @name index.js + * @author Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ + * @license + * Copyright (C) 2021: + * Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ + * + * This program is free software: you can redistribute it and/or modify it + * under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation, either version 3 of the License, or (at + * your option) any later version. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero + * General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see http://www.gnu.org/licenses/. + */ + +console.log('hello world'); diff --git a/static/fonts/open-sans-v17-latin-700.woff b/static/fonts/open-sans-v17-latin-700.woff new file mode 100644 index 0000000000000000000000000000000000000000..b8b46d0b406e5a1351f2885608bbccb29e7d9cfe Binary files /dev/null and b/static/fonts/open-sans-v17-latin-700.woff differ diff --git a/static/fonts/open-sans-v17-latin-700.woff2 b/static/fonts/open-sans-v17-latin-700.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..3a38286c672d781462fb22dc0b27393c8972ad13 Binary files /dev/null and b/static/fonts/open-sans-v17-latin-700.woff2 differ diff --git a/static/fonts/open-sans-v17-latin-regular.woff b/static/fonts/open-sans-v17-latin-regular.woff new file mode 100644 index 0000000000000000000000000000000000000000..39e88ed924601b969b06137854f24bf029b6cbb3 Binary files /dev/null and b/static/fonts/open-sans-v17-latin-regular.woff differ diff --git a/static/fonts/open-sans-v17-latin-regular.woff2 b/static/fonts/open-sans-v17-latin-regular.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..e9f58b775ec05aedecb58eaa34d0fd2a8d5d1aae Binary files /dev/null and b/static/fonts/open-sans-v17-latin-regular.woff2 differ diff --git a/static/fonts/quicksand-v21-latin-700.woff b/static/fonts/quicksand-v21-latin-700.woff new file mode 100644 index 0000000000000000000000000000000000000000..9f91355ef0da4de3fa188cb2d6698714cdab5305 Binary files /dev/null and b/static/fonts/quicksand-v21-latin-700.woff differ diff --git a/static/fonts/quicksand-v21-latin-700.woff2 b/static/fonts/quicksand-v21-latin-700.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..a4c4103e9c1641888aaa8be90455adfbda2ee667 Binary files /dev/null and b/static/fonts/quicksand-v21-latin-700.woff2 differ diff --git a/static/fonts/quicksand-v21-latin-regular.woff b/static/fonts/quicksand-v21-latin-regular.woff new file mode 100644 index 0000000000000000000000000000000000000000..6696a743dc3c13c4ac80d5c18d678c876102648a Binary files /dev/null and b/static/fonts/quicksand-v21-latin-regular.woff differ diff --git a/static/fonts/quicksand-v21-latin-regular.woff2 b/static/fonts/quicksand-v21-latin-regular.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..335ba07b2ab01102048a2b948fd28827a4bcee65 Binary files /dev/null and b/static/fonts/quicksand-v21-latin-regular.woff2 differ diff --git a/static/images/background.jpg b/static/images/background.jpg new file mode 100644 index 0000000000000000000000000000000000000000..ed3f7b0faf8f772f6b7fa472f6a5c7ab84731a03 Binary files /dev/null and b/static/images/background.jpg differ diff --git a/static/images/button-info.svg b/static/images/button-info.svg new file mode 100644 index 0000000000000000000000000000000000000000..c4c13b7e5131c06bfde5c7e1cf3db47be32bf263 --- /dev/null +++ b/static/images/button-info.svg @@ -0,0 +1,49 @@ + + + + + + + image/svg+xml + + + + + + + + i + +