mirror of
https://github.com/Lissy93/dashy.git
synced 2024-11-23 04:34:44 +03:00
Adds variable size for Font Awesome, and upgrades to premium
This commit is contained in:
parent
628f7f2868
commit
33127ab414
@ -14,7 +14,7 @@
|
|||||||
<div class="overflow-dots">...</div>
|
<div class="overflow-dots">...</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- Item Icon -->
|
<!-- Item Icon -->
|
||||||
<Icon :icon="icon" :url="url" />
|
<Icon :icon="icon" :url="url" :size="itemSize" />
|
||||||
<!-- Small icon, showing opening method on hover -->
|
<!-- Small icon, showing opening method on hover -->
|
||||||
<ItemOpenMethodIcon class="opening-method-icon" :isSmall="!icon" :openingMethod="target"
|
<ItemOpenMethodIcon class="opening-method-icon" :isSmall="!icon" :openingMethod="target"
|
||||||
:position="itemSize === 'medium'? 'bottom right' : 'top right'"/>
|
:position="itemSize === 'medium'? 'bottom right' : 'top right'"/>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<i v-if="determineImageType(icon) === 'font-awesome'" :class="icon"></i>
|
<i v-if="determineImageType(icon) === 'font-awesome'" :class="`${icon} ${size}`"></i>
|
||||||
<img v-else-if="icon" :src="getIconPath(icon, url)" class="tile-icon" />
|
<img v-else-if="icon" :src="getIconPath(icon, url)" :class="`tile-icon ${size}`" />
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
@ -8,8 +8,9 @@
|
|||||||
export default {
|
export default {
|
||||||
name: 'Icon',
|
name: 'Icon',
|
||||||
props: {
|
props: {
|
||||||
icon: String,
|
icon: String, // Path to icon asset
|
||||||
url: String,
|
url: String, // Used for fetching the favicon
|
||||||
|
size: String, // Either small, medium or large
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
/* Check if a string is in a URL format. Used to identify tile icon source */
|
/* Check if a string is in a URL format. Used to identify tile icon source */
|
||||||
@ -72,8 +73,15 @@ export default {
|
|||||||
width: 60px;
|
width: 60px;
|
||||||
filter: var(--item-icon-transform);
|
filter: var(--item-icon-transform);
|
||||||
}
|
}
|
||||||
i.fas, i.fab {
|
i.fas, i.fab, i.far, i.fal, i.fad {
|
||||||
font-size: 1.5rem;
|
font-size: 2rem;
|
||||||
color: currentColor;
|
color: currentColor;
|
||||||
|
margin: 1px auto 4px;
|
||||||
|
&.small {
|
||||||
|
font-size: 1.5rem;
|
||||||
|
}
|
||||||
|
&.large {
|
||||||
|
font-size: 3rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -7,7 +7,7 @@ module.exports = {
|
|||||||
iconSize: 'medium',
|
iconSize: 'medium',
|
||||||
layout: 'auto',
|
layout: 'auto',
|
||||||
theme: 'default',
|
theme: 'default',
|
||||||
fontAwesomeKey: 'def7c3ce4c',
|
fontAwesomeKey: '0821c65656',
|
||||||
builtInThemes: [
|
builtInThemes: [
|
||||||
'nord',
|
'nord',
|
||||||
'nord-frost',
|
'nord-frost',
|
||||||
|
Loading…
Reference in New Issue
Block a user