mirror of
https://github.com/kevinveenbirkenbach/homepage.veen.world.git
synced 2025-01-15 19:23:58 +01:00
Optimized menu
This commit is contained in:
parent
861fd29d45
commit
4ca34b55de
@ -58,13 +58,5 @@ def reload_config_in_dev():
|
|||||||
def index():
|
def index():
|
||||||
return render_template("pages/index.html.j2", cards=config_data.get("cards", []), networks=config_data.get("networks", []), company=config_data["company"], navigation=config_data["navigation"])
|
return render_template("pages/index.html.j2", cards=config_data.get("cards", []), networks=config_data.get("networks", []), company=config_data["company"], navigation=config_data["navigation"])
|
||||||
|
|
||||||
@app.route('/imprint')
|
|
||||||
def imprint():
|
|
||||||
return render_template('pages/imprint.html.j2')
|
|
||||||
|
|
||||||
@app.route('/agb')
|
|
||||||
def agb():
|
|
||||||
return render_template('pages/agb.html.j2')
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
app.run(debug=(FLASK_ENV == "development"), host="0.0.0.0", port=5000)
|
app.run(debug=(FLASK_ENV == "development"), host="0.0.0.0", port=5000)
|
@ -186,8 +186,7 @@
|
|||||||
"name": "Nature",
|
"name": "Nature",
|
||||||
"description": "Explore my nature logs",
|
"description": "Explore my nature logs",
|
||||||
"icon_class": "fa-solid fa-tree",
|
"icon_class": "fa-solid fa-tree",
|
||||||
"href": "https://s.veen.world/naturejournal",
|
"href": "https://s.veen.world/naturejournal"
|
||||||
"subitems": []
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@ -197,9 +196,10 @@
|
|||||||
"footer":
|
"footer":
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"name": "Third Party Plattforms",
|
"name": "External Accounts",
|
||||||
"description" : "Me on other plattforms",
|
"description" : "Me on other plattforms",
|
||||||
"subitems:":[
|
"icon_class" : "fa-solid fa-external-link-alt",
|
||||||
|
"subitems":[
|
||||||
{
|
{
|
||||||
"name": "Meta",
|
"name": "Meta",
|
||||||
"description": "Social and developer networks",
|
"description": "Social and developer networks",
|
||||||
@ -219,8 +219,30 @@
|
|||||||
"icon_class": "fa-brands fa-facebook",
|
"icon_class": "fa-brands fa-facebook",
|
||||||
"href": "https://www.facebook.com/kevinveenbirkenbach",
|
"href": "https://www.facebook.com/kevinveenbirkenbach",
|
||||||
"subitems": []
|
"subitems": []
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Carreer Profiles",
|
||||||
|
"icon_class": "fa-solid fa-user-tie",
|
||||||
|
"subitems": [
|
||||||
|
{
|
||||||
|
"name": "XING",
|
||||||
|
"description": "Visit my XING profile",
|
||||||
|
"icon_class": "bi bi-building",
|
||||||
|
"href": "https://www.xing.com/profile/Kevin_VeenBirkenbach",
|
||||||
|
"subitems": []
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "LinkedIn",
|
||||||
|
"description": "Connect on LinkedIn",
|
||||||
|
"icon_class": "bi bi-linkedin",
|
||||||
|
"href": "https://www.linkedin.com/in/kevinveenbirkenbach",
|
||||||
|
"subitems": []
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Duolingo",
|
"name": "Duolingo",
|
||||||
"description": "Learn with me on Duolingo",
|
"description": "Learn with me on Duolingo",
|
||||||
"icon_class": "fa-solid fa-language",
|
"icon_class": "fa-solid fa-language",
|
||||||
@ -233,14 +255,20 @@
|
|||||||
"icon_class": "fa-brands fa-spotify",
|
"icon_class": "fa-brands fa-spotify",
|
||||||
"href": "https://open.spotify.com/user/31vebfzbjf3p7oualis76qfpr5ty",
|
"href": "https://open.spotify.com/user/31vebfzbjf3p7oualis76qfpr5ty",
|
||||||
"subitems": []
|
"subitems": []
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Patreon",
|
||||||
|
"description": "Support me on Patreon",
|
||||||
|
"icon_class": "fa-brands fa-patreon",
|
||||||
|
"href": "https://patreon.com/kevinveenbirkenbach",
|
||||||
|
"subitems": []
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Community",
|
"name": "Community",
|
||||||
"description": "My presence in the Fediverse",
|
"description": "My presence in the Fediverse",
|
||||||
"icon_class": "fa-brands fa-mastodon",
|
"icon_class": "fa-solid fa-users",
|
||||||
"href": null,
|
|
||||||
"subitems": [
|
"subitems": [
|
||||||
|
|
||||||
{
|
{
|
||||||
@ -256,18 +284,10 @@
|
|||||||
"icon_class": "fa-solid fa-envelope-open-text",
|
"icon_class": "fa-solid fa-envelope-open-text",
|
||||||
"href": "https://newsletter.veen.world/subscription/form",
|
"href": "https://newsletter.veen.world/subscription/form",
|
||||||
"subitems": []
|
"subitems": []
|
||||||
},
|
}
|
||||||
{
|
|
||||||
"name": "Patreon",
|
|
||||||
"description": "Support me on Patreon",
|
|
||||||
"icon_class": "fa-brands fa-patreon",
|
|
||||||
"href": "https://patreon.com/kevinveenbirkenbach",
|
|
||||||
"subitems": []
|
|
||||||
}
|
|
||||||
]
|
]
|
||||||
}
|
},
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "Work Hub",
|
"name": "Work Hub",
|
||||||
"description": "Curated collection of self hosted tools for work, organization, and learning.",
|
"description": "Curated collection of self hosted tools for work, organization, and learning.",
|
||||||
@ -347,26 +367,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "Carreer Profiles",
|
|
||||||
"icon_class": "fa-solid fa-user-tie",
|
|
||||||
"subitems": [
|
|
||||||
{
|
|
||||||
"name": "XING",
|
|
||||||
"description": "Visit my XING profile",
|
|
||||||
"icon_class": "bi bi-building",
|
|
||||||
"href": "https://www.xing.com/profile/Kevin_VeenBirkenbach",
|
|
||||||
"subitems": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "LinkedIn",
|
|
||||||
"description": "Connect on LinkedIn",
|
|
||||||
"icon_class": "bi bi-linkedin",
|
|
||||||
"href": "https://www.linkedin.com/in/kevinveenbirkenbach",
|
|
||||||
"subitems": []
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "Contact",
|
"name": "Contact",
|
||||||
"description": "Get in touch",
|
"description": "Get in touch",
|
||||||
|
@ -66,18 +66,34 @@ h3.footer-title{
|
|||||||
padding: 0px;
|
padding: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.dropdown-menu {
|
||||||
|
position: absolute !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dropdown-menu-footer {
|
||||||
|
position: absolute !important;
|
||||||
|
top: auto !important;
|
||||||
|
bottom: 100%; /* Positioniert das Menü über dem Auslöser */
|
||||||
|
transform: translateY(-10px); /* Optional: Sanfter Abstand */
|
||||||
|
}
|
||||||
|
|
||||||
.dropdown-submenu {
|
.dropdown-submenu {
|
||||||
position: relative;
|
position: relative;
|
||||||
list-style: none;
|
list-style: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-submenu > .dropdown-menu {
|
|
||||||
top: 0;
|
|
||||||
left: 100%;
|
|
||||||
margin-top: -0.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-nav {
|
.navbar-nav {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
}
|
||||||
|
/* Stellt sicher, dass Submenüs korrekt positioniert sind */
|
||||||
|
.dropdown-submenu {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dropdown-submenu > .dropdown-menu {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 100%; /* Positioniert das Submenü rechts vom Hauptmenü */
|
||||||
|
margin-top: -1px;
|
||||||
}
|
}
|
@ -1,12 +1,12 @@
|
|||||||
<!-- Template for Subitems -->
|
<!-- Template for Subitems -->
|
||||||
{% macro render_subitems(subitems) %}
|
{% macro render_subitems(subitems) %}
|
||||||
{% for subitem in subitems %}
|
{% for subitem in subitems %}
|
||||||
{% if subitems.subitems %}
|
{% if subitem.subitems %}
|
||||||
<li class="dropdown-submenu">
|
<li class="dropdown-submenu">
|
||||||
<a class="dropdown-item dropdown-toggle" href="#" data-bs-toggle="tooltip" title="{{ subitem.description }}">
|
<a class="dropdown-item dropdown-toggle" href="#" data-bs-toggle="tooltip" title="{{ subitem.description }}">
|
||||||
<i class="{{ subitem.icon_class }}"></i> {{ subitem.name }}
|
<i class="{{ subitem.icon_class }}"></i> {{ subitem.name }}
|
||||||
</a>
|
</a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-submenu">
|
||||||
{{ render_subitems(subitem.subitems) }}
|
{{ render_subitems(subitem.subitems) }}
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
@ -48,10 +48,10 @@
|
|||||||
{% else %}
|
{% else %}
|
||||||
<!-- Dropdown Menu -->
|
<!-- Dropdown Menu -->
|
||||||
<li class="nav-item dropdown">
|
<li class="nav-item dropdown">
|
||||||
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown{{ loop.index }}" role="button" data-bs-toggle="dropdown" data-bs-toggle="tooltip" title="{{ item.description }}" aria-expanded="false">
|
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown{{ loop.index }}" role="button" data-bs-toggle="dropdown" data-bs-display="dynamic" data-popper-placement="top" title="{{ item.description }}" aria-expanded="false">
|
||||||
<i class="{{ item.icon_class }}"></i> {{ item.name }}
|
<i class="{{ item.icon_class }}" data-bs-toggle="tooltip"></i> {{ item.name }}
|
||||||
</a>
|
</a>
|
||||||
<ul class="dropdown-menu" aria-labelledby="navbarDropdown{{ loop.index }}">
|
<ul class="dropdown-menu dropdown-menu-{{menu_type}}" aria-labelledby="navbarDropdown{{ loop.index }}">
|
||||||
{{ render_subitems(item.subitems) }}
|
{{ render_subitems(item.subitems) }}
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
|
Loading…
Reference in New Issue
Block a user