add dot-only prop to DotButton
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<b-button
|
||||
class="dot-btn"
|
||||
:class="['dot-btn-' + variant, { 'active': active, 'show': show }]"
|
||||
:class="['dot-btn-' + variant, { 'active': active, 'show': show, 'hide': dotOnly }]"
|
||||
v-bind="$attrs" v-on="$listeners"
|
||||
:active="active"
|
||||
:variant="variant"
|
||||
@@ -24,7 +24,8 @@ export default {
|
||||
props: {
|
||||
variant: { type: String, required: true },
|
||||
active: { type: Boolean, default: false },
|
||||
hovered: { type: Boolean, default: false }
|
||||
hovered: { type: Boolean, default: false },
|
||||
dotOnly: { type: Boolean, default: false }
|
||||
},
|
||||
|
||||
data () {
|
||||
@@ -52,7 +53,8 @@ export default {
|
||||
word-break: keep-all;
|
||||
white-space: pre;
|
||||
|
||||
&:not(.show) {
|
||||
&:not(.show),
|
||||
&.hide {
|
||||
min-height: 1.1875rem;
|
||||
min-width: 1.1875rem;
|
||||
padding: 0;
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
@click="onOpen(child.id)"
|
||||
:variant="child.variant"
|
||||
:active="activeNodes.includes(child.id)"
|
||||
dot-only
|
||||
>
|
||||
{{ $t('variants.' + child.variant) }}
|
||||
</dot-button>
|
||||
|
||||
Reference in New Issue
Block a user