Update quick links

This commit is contained in:
Linux User 2021-02-22 21:24:10 +01:00
parent 7ffa732e68
commit 4cacb43fb6
4 changed files with 6 additions and 16 deletions

View File

@ -30,7 +30,7 @@
}
#section-0 {
background-image: url(https://www.uni-bamberg.de/fileadmin/uni/verwaltung/presse/044_PRESSE/Pressebilder-offiziell/Gebaeude_neu/An-der-Weberei-5-Bild3.jpg);
# background-image: url(https://www.uni-bamberg.de/fileadmin/uni/verwaltung/presse/044_PRESSE/Pressebilder-offiziell/Gebaeude_neu/An-der-Weberei-5-Bild3.jpg);
background-size: cover;
background-position: center 61%;
}

View File

@ -9,8 +9,6 @@ const quickLinks = [
name_english: "Virtual Map",
url_german: "https://wiai.de/home",
url_english: "https://wiai.de/home",
background: "#6731b7",
color: "white",
icon: "gamepad"
},
{
@ -18,17 +16,13 @@ const quickLinks = [
name_english: "Teams",
url_german: "#",
url_english: "#",
background: "#6731b7",
color: "transparent",
logo: "microsoft-teams.jpg"
icon: "headset"
},
{
name_german: "Zeitplan",
name_english: "Schedule",
url_german: "#",
url_english: "#",
background: "#6731b7",
color: "white",
icon: "calendar-alt"
},
{
@ -36,8 +30,6 @@ const quickLinks = [
name_english: "Help & FAQ",
url_german: "https://vc.uni-bamberg.de/mod/page/view.php?id=1122808",
url_english: "#",
background: "#6731b7",
color: "white",
icon: "question-circle"
},
{
@ -45,8 +37,6 @@ const quickLinks = [
name_english: "Glossary",
url_german: "https://vc.uni-bamberg.de/mod/glossary/view.php?id=1122803",
url_english: "https://vc.uni-bamberg.de/mod/glossary/view.php?id=1122803",
background: "#6731b7",
color: "white",
icon: "book"
}
]
@ -95,13 +85,15 @@ function addQuickLinks() {
quickLinkContainer.classList.add('wiai-quick-link-container');
firstSection.prepend(quickLinkContainer);
const bgColor = '#FFDC33', color = '#1A171B';
quickLinkContainer.style.setProperty('--bg-color', bgColor);
quickLinkContainer.style.setProperty('--color', color);
quickLinks.forEach(function(quickLink) {
const element = document.createElement('a');
element.href = quickLink.url_german
element.classList.add('wiai-quick-link');
element.classList.add('wiai-german');
element.style.setProperty('--bg-color', quickLink.background);
element.style.setProperty('--color', quickLink.color);
if (quickLink.logo) {
element.style.setProperty('--bg-image', `url(${URL}${LOGO_URL}${quickLink.logo})`);
@ -117,8 +109,6 @@ function addQuickLinks() {
elementEnglish.href = quickLink.url_english
elementEnglish.classList.add('wiai-quick-link');
elementEnglish.classList.add('wiai-english');
elementEnglish.style.setProperty('--bg-color', quickLink.background);
elementEnglish.style.setProperty('--color', quickLink.color);
if (quickLink.logo) {
elementEnglish.style.setProperty('--bg-image', `url(${URL}${LOGO_URL}${quickLink.logo})`);

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB