diff --git a/frontend/public/favicon.ico b/frontend/public/favicon.ico deleted file mode 100644 index a11777cc471a4344702741ab1c8a588998b1311a..0000000000000000000000000000000000000000 Binary files a/frontend/public/favicon.ico and /dev/null differ diff --git a/frontend/public/favicons/uib.ico b/frontend/public/favicons/uib.ico new file mode 100644 index 0000000000000000000000000000000000000000..ebfef37945e54171584a7cb14d1ae07a0e422e26 Binary files /dev/null and b/frontend/public/favicons/uib.ico differ diff --git a/frontend/public/favicons/uio.svg b/frontend/public/favicons/uio.svg new file mode 100644 index 0000000000000000000000000000000000000000..ecea2284c2821e74faa169f65012a5cbac466002 --- /dev/null +++ b/frontend/public/favicons/uio.svg @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<svg width="33px" height="15px" viewBox="0 0 33 15" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> + <title>UiO_Forkortelse_B</title> + <defs> + <polygon id="path-1" points="0 0.254597753 13.2565213 0.254597753 13.2565213 12.9438202 0 12.9438202"></polygon> + <polygon id="path-3" points="0.201348315 0.270130337 13.3033708 0.270130337 13.3033708 13.3033708 0.201348315 13.3033708"></polygon> + </defs> + <g id="Ikoner" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"> + <g id="Favicon" transform="translate(-621.000000, -609.000000)"> + <g id="Group-11" transform="translate(621.041603, 609.000000)"> + <g id="Group-3" transform="translate(0.000000, 1.120935)"> + <mask id="mask-2" fill="white"> + <use xlink:href="#path-1"></use> + </mask> + <g id="Clip-2"></g> + <path d="M-0.000107865169,0.564170787 L-0.000107865169,0.254597753 L5.76025169,0.254597753 L5.76025169,0.564170787 C4.09229663,0.770193258 4.05777978,0.976575281 4.05777978,2.7822382 L4.05777978,7.75122697 C4.05777978,10.4507326 4.9688809,11.9637213 7.30739775,11.9637213 C9.8350382,11.9637213 10.6947236,10.1925753 10.7464989,7.6135191 L10.7464989,2.76497978 C10.7464989,0.993833708 10.711982,0.770193258 9.04402697,0.564170787 L9.04402697,0.254597753 L13.2565213,0.254597753 L13.2565213,0.564170787 C11.5889258,0.770193258 11.554409,0.993833708 11.554409,2.76497978 L11.554409,7.5793618 C11.554409,11.310418 9.81813933,12.9438562 6.74002697,12.9438562 C3.31818427,12.9438562 1.70200449,11.1730697 1.70200449,7.99176629 L1.70200449,2.7822382 C1.70200449,1.01109213 1.66784719,0.770193258 -0.000107865169,0.564170787" id="Fill-1" fill="#000000" mask="url(#mask-2)"></path> + </g> + <path d="M17.0062022,11.3652494 C17.0062022,13.1363955 17.0238202,13.3769348 18.3818427,13.5315416 L18.3818427,13.8414742 L13.4642697,13.8414742 L13.4642697,13.5315416 C14.8230112,13.3769348 14.8399101,13.1363955 14.8399101,11.3652494 L14.8399101,7.7546427 C14.8399101,5.9320809 14.7198202,5.91482247 13.4642697,5.88030562 L13.4642697,5.58835056 L17.0579775,4.43635056 C17.0407191,5.34745169 17.0062022,6.48219326 17.0062022,8.2360809 L17.0062022,11.3652494 Z" id="Fill-4" fill="#000000"></path> + <g id="Group-8" transform="translate(18.696629, 0.761384)"> + <mask id="mask-4" fill="white"> + <use xlink:href="#path-3"></use> + </mask> + <g id="Clip-7"></g> + <path d="M6.75235955,0.906534831 C4.37932584,0.906534831 2.83217978,3.1591191 2.83217978,6.78662472 C2.83217978,10.4144899 4.37932584,12.6670742 6.75235955,12.6670742 C9.12539326,12.6670742 10.6725393,10.4144899 10.6725393,6.78662472 C10.6725393,3.1591191 9.12539326,0.906534831 6.75235955,0.906534831 M6.75235955,0.270130337 C10.122427,0.270130337 13.3033708,2.53997303 13.3033708,6.78662472 C13.3033708,11.033636 10.122427,13.3034787 6.75235955,13.3034787 C3.38229213,13.3034787 0.201348315,11.033636 0.201348315,6.78662472 C0.201348315,2.53997303 3.38229213,0.270130337 6.75235955,0.270130337" id="Fill-6" fill="#000000" mask="url(#mask-4)"></path> + </g> + <path d="M14.4099955,1.35820225 C14.4099955,0.601707865 15.0464,0.000179775281 15.8201528,0.000179775281 C16.6108045,0.000179775281 17.2299506,0.601707865 17.2299506,1.35820225 C17.2299506,2.13195506 16.6108045,2.75110112 15.8201528,2.75110112 C15.0464,2.75110112 14.4099955,2.13195506 14.4099955,1.35820225" id="Fill-9" fill="#000000"></path> + </g> + </g> + </g> +</svg> \ No newline at end of file diff --git a/frontend/public/index.html b/frontend/public/index.html index 979dbe86168f4c2ed54e40f548c0b1c76571757d..e5438ae12b61deccec1977821712ab05fda03a02 100644 --- a/frontend/public/index.html +++ b/frontend/public/index.html @@ -2,18 +2,20 @@ <html lang="en"> <head> <meta charset="utf-8" /> - <link rel="icon" href="%PUBLIC_URL%/favicon.ico" /> <meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="theme-color" content="#000000" /> <meta name="description" - content="Web site created using create-react-app" + content="Web site for registering guests at the university." /> <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" /> <link rel="manifest" href="%PUBLIC_URL%/manifest.json" /> - <link rel="preconnect" href="https://fonts.googleapis.com"> - <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> - <link href="https://fonts.googleapis.com/css2?family=Open+Sans&display=swap" rel="stylesheet"> + <link rel="preconnect" href="https://fonts.googleapis.com" /> + <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> + <link + href="https://fonts.googleapis.com/css2?family=Open+Sans&display=swap" + rel="stylesheet" + /> <title>Guest Registration</title> </head> <body> diff --git a/frontend/public/logo192.png b/frontend/public/logo192.png deleted file mode 100644 index fc44b0a3796c0e0a64c3d858ca038bd4570465d9..0000000000000000000000000000000000000000 Binary files a/frontend/public/logo192.png and /dev/null differ diff --git a/frontend/public/logo512.png b/frontend/public/logo512.png deleted file mode 100644 index a4e47a6545bc15971f8f63fba70e4013df88a664..0000000000000000000000000000000000000000 Binary files a/frontend/public/logo512.png and /dev/null differ diff --git a/frontend/public/manifest.json b/frontend/public/manifest.json index 080d6c77ac21bb2ef88a6992b2b73ad93daaca92..82e3f724a86b648ad937da96d398a065ed747b89 100644 --- a/frontend/public/manifest.json +++ b/frontend/public/manifest.json @@ -1,23 +1,6 @@ { "short_name": "React App", - "name": "Create React App Sample", - "icons": [ - { - "src": "favicon.ico", - "sizes": "64x64 32x32 24x24 16x16", - "type": "image/x-icon" - }, - { - "src": "logo192.png", - "type": "image/png", - "sizes": "192x192" - }, - { - "src": "logo512.png", - "type": "image/png", - "sizes": "512x512" - } - ], + "name": "Guest Service", "start_url": ".", "display": "standalone", "theme_color": "#000000", diff --git a/frontend/src/components/page/page.tsx b/frontend/src/components/page/page.tsx index 55d1864388a52c0e7da41665bfd15da591a3ddc3..1b62e32b67c6f97ba66aba6b0f5735ef832820f0 100644 --- a/frontend/src/components/page/page.tsx +++ b/frontend/src/components/page/page.tsx @@ -4,6 +4,7 @@ import { useTranslation } from 'react-i18next' import { styled } from '@mui/material/styles' import { Container } from '@mui/material' +import { appInst } from 'appConfig' const StyledPageHeader = styled('h2')(({ theme }) => ({ color: theme.greg.textWhite, @@ -17,6 +18,19 @@ interface IPage { header?: string } +let faviconPath = '' + +switch (appInst) { + case 'uib': + faviconPath = 'favicons/uib.ico' + break + case 'uio': + faviconPath = 'favicons/uio.svg' + break + default: + faviconPath = 'favicons/uio.svg' +} + export default function Page(props: IPage) { const { header, children } = props const { i18n, t } = useTranslation() @@ -25,6 +39,7 @@ export default function Page(props: IPage) { return ( <> <Helmet titleTemplate={`%s - ${appTitle}`} defaultTitle={appTitle}> + <link rel="icon" href={faviconPath} /> <html lang={i18n.language} /> <title>{header}</title> </Helmet>