Skip to content

Commit

Permalink
Merge pull request #150 from sairina/krouterlink-icon
Browse files Browse the repository at this point in the history
Add purple clickable icons for KRouterLink
  • Loading branch information
indirectlylit authored Feb 19, 2021
2 parents 7b44484 + 0827090 commit ed0b127
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions lib/buttons-and-links/KRouterLink.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,30 @@
:replace="replace"
dir="auto"
>
<KLabeledIcon :maxWidth="maxWidth" @mouseenter="hovering = true" @mouseleave="hovering = false">
<KLabeledIcon
:maxWidth="maxWidth"
@mouseenter="hovering = true"
@mouseleave="hovering = false"
>
<KIcon
v-if="icon"
slot="icon"
:icon="icon"
style="top: 0px; height: 24px; width: 24px;"
style="top: 2px;"
:color="hovering ? $themeTokens.primaryDark : $themeTokens.primary"
/>

<!-- Keep on the same line to avoid empty underlined spacing -->
<slot name="text" :text="text">
<span class="link-text">{{ text }}</span>
</slot>
<span class="link-text">{{ text }}</span>

<KIcon
v-if="iconAfter"
slot="iconAfter"
:icon="iconAfter"
style="top: 0px; height: 24px; width: 24px;"
style="top: 2px;"
:color="hovering ? $themeTokens.primaryDark : $themeTokens.primary"
/>


</KLabeledIcon>
</router-link>

Expand Down

0 comments on commit ed0b127

Please sign in to comment.