mini mfm button

This commit is contained in:
Freeplay 2023-05-19 14:34:16 -04:00
parent 79af6df55e
commit d60002f426
2 changed files with 10 additions and 2 deletions

View File

@ -2,7 +2,7 @@
<button <button
v-if="!link" v-if="!link"
class="bghgjjyj _button" class="bghgjjyj _button"
:class="{ inline, primary, gradate, danger, rounded, full }" :class="{ inline, primary, gradate, danger, rounded, full, mini }"
:type="type" :type="type"
@click="emit('click', $event)" @click="emit('click', $event)"
@mousedown="onMousedown" @mousedown="onMousedown"
@ -15,7 +15,7 @@
<MkA <MkA
v-else v-else
class="bghgjjyj _button" class="bghgjjyj _button"
:class="{ inline, primary, gradate, danger, rounded, full }" :class="{ inline, primary, gradate, danger, rounded, full, mini }"
:to="to" :to="to"
@mousedown="onMousedown" @mousedown="onMousedown"
> >
@ -41,6 +41,7 @@ const props = defineProps<{
wait?: boolean; wait?: boolean;
danger?: boolean; danger?: boolean;
full?: boolean; full?: boolean;
mini: boolean;
}>(); }>();
const emit = defineEmits<{ const emit = defineEmits<{
@ -190,6 +191,12 @@ function onMousedown(evt: MouseEvent): void {
} }
} }
&.mini {
padding: 4px 8px;
font-size: .9em;
border-radius: 100px;
}
&:disabled { &:disabled {
opacity: 0.7; opacity: 0.7;
} }

View File

@ -133,6 +133,7 @@
<MkButton <MkButton
v-if="hasMfm && defaultStore.state.animatedMfm" v-if="hasMfm && defaultStore.state.animatedMfm"
@click.stop="toggleMfm" @click.stop="toggleMfm"
:mini="true"
> >
<template v-if="disableMfm"> <template v-if="disableMfm">
<i class="ph-play ph-bold"></i> {{ i18n.ts._mfm.play }} <i class="ph-play ph-bold"></i> {{ i18n.ts._mfm.play }}