diff --git a/app-template/.htaccess b/app-template/.htaccess new file mode 100644 index 0000000000000000000000000000000000000000..8cdfd02257a47b904b18f2be12174f6a0ee0b348 --- /dev/null +++ b/app-template/.htaccess @@ -0,0 +1,13 @@ +DirectoryIndex /index.html +# DirectoryIndex /dist/dbp-signature-maintenance.html +<FilesMatch "^(de|en|)$"> + FallbackResource /index.html +</FilesMatch> + +Header set Cache-Control "must-revalidate, max-age=60" +Header set Content-Security-Policy "default-src 'self' 'unsafe-eval' 'unsafe-inline' http://127.0.0.1:8000 www.handy-signatur.at; img-src * blob: data:; font-src 'self' data:" + +# Apache adds a "-gzip" suffix to the etag when it uses gzip but doesn't +# take that into account when receiving requests. +# See https://bz.apache.org/bugzilla/show_bug.cgi?id=45023 +RequestHeader edit "If-None-Match" '^"((.*)-(gzip|br))"$' '"$1", "$2"' \ No newline at end of file diff --git a/app-template/icons/favicon.ico b/app-template/icons/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..50a2c752cd4560bf1a0aa11c63575777ab69a29b Binary files /dev/null and b/app-template/icons/favicon.ico differ diff --git a/app-template/icons/favicon.svg b/app-template/icons/favicon.svg new file mode 100644 index 0000000000000000000000000000000000000000..711030bf58c8cee707670764be7f1ffcbe0436dd --- /dev/null +++ b/app-template/icons/favicon.svg @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<svg id="svg49" width="53" height="53" version="1.1" viewBox="0 0 14.023 14.023" xmlns="http://www.w3.org/2000/svg" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:xlink="http://www.w3.org/1999/xlink"> + <metadata id="metadata53"> + <rdf:RDF> + <cc:Work rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/> + <dc:title/> + </cc:Work> + </rdf:RDF> + </metadata> + <style id="style2"><![CDATA[.B{fill:#c8c7c7}.C{fill:#231f20}]]></style> + <path id="path4" class="B" d="m0.41352 6.0395v0.313l5.866 3.295 5.927-3.295v-0.313l-5.897 3.295z" fill="#c8c7c7"/> + <path id="path6" class="C" d="m6.2785 9.6465 5.927-3.295v-0.313l-5.896 3.296z" fill="#231f20"/> + <path id="path8" class="B" d="m0.41352 7.6785v0.312l5.866 3.295 5.927-3.295v-0.312l-5.897 3.295z" fill="#c8c7c7"/> + <path id="path10" class="C" d="m6.2785 11.286 5.927-3.295v-0.312l-5.896 3.295z" fill="#231f20"/> + <path id="path12" class="B" d="m0.41352 9.3175v0.313l5.866 3.295 5.927-3.295v-0.313l-5.896 3.295z" fill="#c8c7c7"/> + <path id="path14" class="C" d="m6.2785 12.924 5.927-3.295v-0.312l-5.897 3.295z" fill="#231f20"/> + <path id="path16" class="B" d="m9.2575 6.0885-1.474-0.824 1.474-0.824 1.474 0.824z" fill="#c8c7c7"/> + <use id="use18" class="C" transform="translate(.41352 1.0975)" width="100%" height="100%" fill="#231f20" xlink:href="#B"/> + <path id="path20" d="m9.1875 4.3925-1.474-0.824 1.474-0.824 1.474 0.824z" fill="#656263"/> + <use id="use22" class="C" transform="translate(.41352 1.0975)" x="-1.474" y="0.82300001" width="100%" height="100%" fill="#231f20" xlink:href="#B"/> + <use id="use24" class="B" transform="translate(.41352 1.0975)" x="-2.948" width="100%" height="100%" fill="#c8c7c7" xlink:href="#B"/> + <g id="g32" transform="translate(.41352 1.0975)" fill="#7b7979"> + <use id="use26" x="-1.474" y="-0.824" width="100%" height="100%" xlink:href="#B"/> + <use id="use28" x="-1.474" y="-2.471" width="100%" height="100%" xlink:href="#B"/> + <path id="path30" d="m4.422 2.471-1.474-0.824 1.474-0.824 1.474 0.824z"/> + </g> + <use id="use34" class="B" transform="translate(.41352 1.0975)" x="-4.4219999" y="-0.824" width="100%" height="100%" fill="#c8c7c7" xlink:href="#B"/> + <path id="path36" class="C" d="m12.136 2.7445-1.473-0.824 1.473-0.823 1.474 0.824z" fill="#231f20"/> + <g id="g42" class="B" transform="translate(.41352 1.0975)" fill="#c8c7c7"> + <path id="path38" d="m8.844 6.589-1.474-0.823 1.474-0.824 1.474 0.824z"/> + <use id="use40" y="1.647" width="100%" height="100%" xlink:href="#B"/> + </g> + <use id="use44" class="C" transform="translate(.41352 1.0975)" x="-4.4219999" y="0.82300001" width="100%" height="100%" fill="#231f20" xlink:href="#B"/> + <defs id="defs47"> + <path id="B" d="m7.37 5.766-1.474-0.824 1.474-0.824 1.474 0.824z"/> + </defs> +</svg> diff --git a/app-template/icons/icon-128x128.png b/app-template/icons/icon-128x128.png new file mode 100644 index 0000000000000000000000000000000000000000..7c5348a88561ea3e218a6dd90f2d01d93761749d Binary files /dev/null and b/app-template/icons/icon-128x128.png differ diff --git a/app-template/icons/icon-144x144.png b/app-template/icons/icon-144x144.png new file mode 100644 index 0000000000000000000000000000000000000000..cc97966d946274c525383379161531e9aeeb4598 Binary files /dev/null and b/app-template/icons/icon-144x144.png differ diff --git a/app-template/icons/icon-152x152.png b/app-template/icons/icon-152x152.png new file mode 100644 index 0000000000000000000000000000000000000000..fbba38ebbddc8440dd31b31fbae2185bfc93404e Binary files /dev/null and b/app-template/icons/icon-152x152.png differ diff --git a/app-template/icons/icon-16x16.png b/app-template/icons/icon-16x16.png new file mode 100644 index 0000000000000000000000000000000000000000..2023c5e67aa884b8d1bb0842a5015d3680bbbda4 Binary files /dev/null and b/app-template/icons/icon-16x16.png differ diff --git a/app-template/icons/icon-180x180.png b/app-template/icons/icon-180x180.png new file mode 100644 index 0000000000000000000000000000000000000000..b866a9bf8fd6b20e24911ef1c2fcb7c4ec4d509d Binary files /dev/null and b/app-template/icons/icon-180x180.png differ diff --git a/app-template/icons/icon-192x192.png b/app-template/icons/icon-192x192.png new file mode 100644 index 0000000000000000000000000000000000000000..78e3fde551337c91d05d92baf8701df9b0b1a3d8 Binary files /dev/null and b/app-template/icons/icon-192x192.png differ diff --git a/app-template/icons/icon-256x256.png b/app-template/icons/icon-256x256.png new file mode 100644 index 0000000000000000000000000000000000000000..4409177ecb521e6714ce7ce7a98dbfae6afbc251 Binary files /dev/null and b/app-template/icons/icon-256x256.png differ diff --git a/app-template/icons/icon-32x32.png b/app-template/icons/icon-32x32.png new file mode 100644 index 0000000000000000000000000000000000000000..af2fab937c1c0bd519edf2485ce967a4228f3269 Binary files /dev/null and b/app-template/icons/icon-32x32.png differ diff --git a/app-template/icons/icon-384x384.png b/app-template/icons/icon-384x384.png new file mode 100644 index 0000000000000000000000000000000000000000..02aeef458b9fa1e22ca1ba4f1825b09d371b44e7 Binary files /dev/null and b/app-template/icons/icon-384x384.png differ diff --git a/app-template/icons/icon-512x512.png b/app-template/icons/icon-512x512.png new file mode 100644 index 0000000000000000000000000000000000000000..1c3041103eee3b8442a2be6d64679496324f4118 Binary files /dev/null and b/app-template/icons/icon-512x512.png differ diff --git a/app-template/icons/icon-72x72.png b/app-template/icons/icon-72x72.png new file mode 100644 index 0000000000000000000000000000000000000000..3b1bf645800ab0ea7ed4adbb0d3012f55bae891e Binary files /dev/null and b/app-template/icons/icon-72x72.png differ diff --git a/app-template/icons/icon-96x96.png b/app-template/icons/icon-96x96.png new file mode 100644 index 0000000000000000000000000000000000000000..849a8cec27ab1c4d146ae47b2644f8ba2fd2c6c1 Binary files /dev/null and b/app-template/icons/icon-96x96.png differ diff --git a/app-template/index.html b/app-template/index.html new file mode 100644 index 0000000000000000000000000000000000000000..3348b35248f347fb504f4a44cc5beb8abb481a7c --- /dev/null +++ b/app-template/index.html @@ -0,0 +1,90 @@ +<!doctype html> +<html> +<head> + <meta charset="UTF-8"> + <meta name="viewport" content="width=device-width, initial-scale=1"> + <meta name="theme-color" content="white"/> + + <!-- Favicons --> + <link rel="shortcut icon" type="image/x-icon" href="/icons/favicon.ico"> + <link rel="icon" type="image/svg+xml" href="/icons/favicon.svg" sizes="any"> + + <!-- PWA manifest file --> + <link rel="manifest" href="/app/dbp-signature.manifest.json"> + + <!-- PWA iphone --> + <link rel="apple-touch-icon" sizes="180x180" href="/icons/apple-touch-icon.png"> + <link rel="icon" type="image/png" sizes="32x32" href="/icons/icon-32x32.png"> + <link rel="icon" type="image/png" sizes="16x16" href="/icons/icon-16x16.png"> + <link rel="mask-icon" href="/icons/safari-pinned-tab.svg" color="#e4154b"> + <meta name="apple-mobile-web-app-status-bar-style" content="white"> + + <!-- Loading spinner --> + <script type="module"> + import {Spinner} from '/app/local/@dbp-topics/signature/spinner.js'; + customElements.define('dbp-loading-spinner', Spinner); + </script> + + <!-- App bundles--> + <script type="module" src="/app/dbp-signature.js"></script> + + <!-- Prevent Chrome/Edge from suggesting to translate the page --> + <meta name="google" content="notranslate"> + + <!-- Font related CSS --> + <style> + @import "/app/local/@dbp-topics/signature/fonts/source-sans-pro/300.css"; + @import "/app/local/@dbp-topics/signature/fonts/source-sans-pro/400.css"; + @import "/app/local/@dbp-topics/signature/fonts/source-sans-pro/600.css"; + + body { + font-family: 'Source Sans Pro', 'Calibri', 'Arial', 'sans-serif'; + font-weight: 300; + margin: 0; + } + + /* TU-Graz style override */ + html { + --dbp-override-primary-bg-color: #245b78; + --dbp-override-primary-button-border: solid 1px #245b78; + --dbp-override-info-bg-color: #245b78; + --dbp-override-danger-bg-color: #e4154b; + --dbp-override-warning-bg-color: #ffe183; + --dbp-override-warning-text-color: black; + --dbp-override-success-bg-color: #259207; + } + </style> +</head> + +<body> +<dbp-signature + provider-root + id="app" + lang="de" entry-point-url="http://127.0.0.1:8000" + show-nextcloud-file-picker + show-clipboard + allow-annotating + html-overrides="global-override" + src="/app/dbp-signature.topic.metadata.json" + base-path="/app/" + keycloak-config='{"url": "https://auth-dev.tugraz.at/auth", "realm": "tugraz", "clientId": "auth-dev-mw-frontend-local", "silentCheckSsoRedirectUri": "/silent-check-sso.html"}' + env='local' +><dbp-loading-spinner></dbp-loading-spinner> +<template slot="name"> + TU Graz<br /> + <dbp-translated subscribe="lang"> + <div slot="de"> + Meine Universität + </div> + <div slot="en"> + My University + </div> + </dbp-translated> +</template> +</dbp-signature> + +<!-- Error handling for too old browsers --> +<script src="/app/local/@dbp-topics/signature/browser-check.js" defer></script> +<noscript>Diese Applikation benötigt Javascript / This application requires Javascript</noscript> +</body> +</html> \ No newline at end of file diff --git a/app-template/silent-check-sso.html b/app-template/silent-check-sso.html new file mode 100644 index 0000000000000000000000000000000000000000..94fe2268cbd7ff3f752f2093bb3cddd6d10b6388 --- /dev/null +++ b/app-template/silent-check-sso.html @@ -0,0 +1,7 @@ +<html> +<body> + <script> + parent.postMessage(location.href, location.origin) + </script> +</body> +</html> \ No newline at end of file diff --git a/package.json b/package.json index bcaf86a6ed48bcc12d0fc4ab4518077eda3ff594..37f01bb92db1782401427415b42b6a5703f09d3b 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@dbp-topics/signature", "internalName": "dbp-signature", - "version": "1.0.13", + "version": "1.0.14", "main": "src/dbp-signature.js", "license": "LGPL-2.1-or-later", "repository": {