mirror of
https://github.com/traefik/traefik.git
synced 2025-09-24 23:31:26 +02:00
40 lines
755 B
Vue
40 lines
755 B
Vue
<template>
|
|
<q-avatar class="provider-logo">
|
|
<q-icon :name="`img:${getLogoPath}`" />
|
|
</q-avatar>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
props: ['name'],
|
|
computed: {
|
|
getLogoPath () {
|
|
const name = this.name.toLowerCase()
|
|
|
|
if (name.startsWith('plugin-')) {
|
|
return 'statics/providers/plugin.svg'
|
|
}
|
|
if (name.startsWith('consul-')) {
|
|
return `statics/providers/consul.svg`
|
|
}
|
|
if (name.startsWith('consulcatalog-')) {
|
|
return `statics/providers/consulcatalog.svg`
|
|
}
|
|
|
|
return `statics/providers/${name}.svg`
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped lang="scss">
|
|
.provider-logo {
|
|
width: 32px;
|
|
height: 32px;
|
|
img {
|
|
width: 100%;
|
|
height: 100%;
|
|
}
|
|
}
|
|
</style>
|