This commit is contained in:
syuilo
2021-10-12 01:04:50 +09:00
parent 50bad84747
commit 36170c816a
2 changed files with 30 additions and 14 deletions

View File

@@ -1,6 +1,5 @@
<template>
<component class="bghgjjyj _button"
:is="link ? 'MkA' : 'button'"
<button v-if="!link" class="bghgjjyj _button"
:class="{ inline, primary, danger, rounded, full }"
:type="type"
@click="$emit('click', $event)"
@@ -10,7 +9,17 @@
<div class="content">
<slot></slot>
</div>
</component>
</button>
<MkA v-else class="bghgjjyj _button"
:class="{ inline, primary, danger, rounded, full }"
:to="to"
@mousedown="onMousedown"
>
<div ref="ripples" class="ripples"></div>
<div class="content">
<slot></slot>
</div>
</MkA>
</template>
<script lang="ts">
@@ -42,6 +51,10 @@ export default defineComponent({
required: false,
default: false
},
to: {
type: String,
required: false
},
autofocus: {
type: Boolean,
required: false,