|
|
|
@ -1,9 +1,19 @@
|
|
|
|
|
<template>
|
|
|
|
|
<li class="NavigationEntry">
|
|
|
|
|
<component
|
|
|
|
|
:is="routeTo ? 'router-link' : 'button'"
|
|
|
|
|
class="menu-item button-unstyled"
|
|
|
|
|
<OptionalRouterLink
|
|
|
|
|
ass="ass"
|
|
|
|
|
:to="routeTo"
|
|
|
|
|
v-slot="{ isActive, href, navigate } = {}"
|
|
|
|
|
>
|
|
|
|
|
<li
|
|
|
|
|
class="NavigationEntry menu-item"
|
|
|
|
|
:class="{ '-active': isActive }"
|
|
|
|
|
v-bind="$attrs"
|
|
|
|
|
>
|
|
|
|
|
<component
|
|
|
|
|
class="main-link button-unstyled"
|
|
|
|
|
:is="routeTo ? 'a' : 'button'"
|
|
|
|
|
:href="href"
|
|
|
|
|
@click="navigate"
|
|
|
|
|
>
|
|
|
|
|
<span>
|
|
|
|
|
<FAIcon
|
|
|
|
@ -21,6 +31,7 @@
|
|
|
|
|
<span class="label">
|
|
|
|
|
{{ item.labelRaw || $t(item.label) }}
|
|
|
|
|
</span>
|
|
|
|
|
</component>
|
|
|
|
|
<slot />
|
|
|
|
|
<div
|
|
|
|
|
v-if="item.badgeGetter && getters[item.badgeGetter]"
|
|
|
|
@ -45,8 +56,8 @@
|
|
|
|
|
icon="thumbtack"
|
|
|
|
|
/>
|
|
|
|
|
</button>
|
|
|
|
|
</component>
|
|
|
|
|
</li>
|
|
|
|
|
</OptionalRouterLink>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script src="./navigation_entry.js"></script>
|
|
|
|
@ -55,7 +66,21 @@
|
|
|
|
|
@import '../../_variables.scss';
|
|
|
|
|
|
|
|
|
|
.NavigationEntry {
|
|
|
|
|
.label {
|
|
|
|
|
display: flex;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
align-items: baseline;
|
|
|
|
|
height: 3.5em;
|
|
|
|
|
line-height: 3.5em;
|
|
|
|
|
padding: 0 1em;
|
|
|
|
|
width: 100%;
|
|
|
|
|
color: $fallback--link;
|
|
|
|
|
color: var(--link, $fallback--link);
|
|
|
|
|
|
|
|
|
|
.timelines-chevron {
|
|
|
|
|
margin-right: 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.main-link {
|
|
|
|
|
flex: 1;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -72,17 +97,6 @@
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.menu-item {
|
|
|
|
|
display: flex;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
align-items: baseline;
|
|
|
|
|
height: 3.5em;
|
|
|
|
|
line-height: 3.5em;
|
|
|
|
|
padding: 0 1em;
|
|
|
|
|
width: 100%;
|
|
|
|
|
color: $fallback--link;
|
|
|
|
|
color: var(--link, $fallback--link);
|
|
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
|
background-color: $fallback--lightBg;
|
|
|
|
|
background-color: var(--selectedMenu, $fallback--lightBg);
|
|
|
|
@ -97,7 +111,7 @@
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
&.router-link-active {
|
|
|
|
|
&.-active {
|
|
|
|
|
font-weight: bolder;
|
|
|
|
|
background-color: $fallback--lightBg;
|
|
|
|
|
background-color: var(--selectedMenu, $fallback--lightBg);
|
|
|
|
@ -116,5 +130,4 @@
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|