mirror of
https://codeberg.org/yeentown/barkey.git
synced 2025-07-07 20:44:34 +00:00
Open boost visibility menu on shift-click
This commit is contained in:
parent
fed5ff50b3
commit
7825f6e95e
6 changed files with 18 additions and 18 deletions
|
@ -132,7 +132,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
class="_button"
|
class="_button"
|
||||||
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
||||||
@click.stop
|
@click.stop
|
||||||
@mousedown.prevent="renoted ? undoRenote(appearNote) : boostVisibility()"
|
@mousedown.prevent="renoted ? undoRenote(appearNote) : boostVisibility($event.shiftKey)"
|
||||||
>
|
>
|
||||||
<i class="ti ti-repeat"></i>
|
<i class="ti ti-repeat"></i>
|
||||||
<p v-if="appearNote.renoteCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
<p v-if="appearNote.renoteCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
||||||
|
@ -506,10 +506,10 @@ if (!props.mock) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function boostVisibility() {
|
function boostVisibility(forceMenu: boolean = false) {
|
||||||
if (renoting) return;
|
if (renoting) return;
|
||||||
|
|
||||||
if (!defaultStore.state.showVisibilitySelectorOnBoost) {
|
if (!defaultStore.state.showVisibilitySelectorOnBoost && !forceMenu) {
|
||||||
renote(defaultStore.state.visibilityOnBoost);
|
renote(defaultStore.state.visibilityOnBoost);
|
||||||
} else {
|
} else {
|
||||||
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
||||||
|
|
|
@ -143,7 +143,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
class="_button"
|
class="_button"
|
||||||
:class="$style.noteFooterButton"
|
:class="$style.noteFooterButton"
|
||||||
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
||||||
@mousedown.prevent="renoted ? undoRenote() : boostVisibility()"
|
@mousedown.prevent="renoted ? undoRenote() : boostVisibility($event.shiftKey)"
|
||||||
>
|
>
|
||||||
<i class="ti ti-repeat"></i>
|
<i class="ti ti-repeat"></i>
|
||||||
<p v-if="appearNote.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
<p v-if="appearNote.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
||||||
|
@ -478,10 +478,10 @@ useTooltip(quoteButton, async (showing) => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
function boostVisibility() {
|
function boostVisibility(forceMenu: boolean = false) {
|
||||||
if (renoting) return;
|
if (renoting) return;
|
||||||
|
|
||||||
if (!defaultStore.state.showVisibilitySelectorOnBoost) {
|
if (!defaultStore.state.showVisibilitySelectorOnBoost && !forceMenu) {
|
||||||
renote(defaultStore.state.visibilityOnBoost);
|
renote(defaultStore.state.visibilityOnBoost);
|
||||||
} else {
|
} else {
|
||||||
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
||||||
|
|
|
@ -31,7 +31,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
class="_button"
|
class="_button"
|
||||||
:class="$style.noteFooterButton"
|
:class="$style.noteFooterButton"
|
||||||
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
||||||
@mousedown="renoted ? undoRenote() : boostVisibility()"
|
@mousedown="renoted ? undoRenote() : boostVisibility($event.shiftKey)"
|
||||||
>
|
>
|
||||||
<i class="ph-rocket-launch ph-bold ph-lg"></i>
|
<i class="ph-rocket-launch ph-bold ph-lg"></i>
|
||||||
<p v-if="note.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ note.renoteCount }}</p>
|
<p v-if="note.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ note.renoteCount }}</p>
|
||||||
|
@ -285,8 +285,8 @@ watch(() => props.expandAllCws, (expandAllCws) => {
|
||||||
if (expandAllCws !== showContent.value) showContent.value = expandAllCws;
|
if (expandAllCws !== showContent.value) showContent.value = expandAllCws;
|
||||||
});
|
});
|
||||||
|
|
||||||
function boostVisibility() {
|
function boostVisibility(forceMenu: boolean = false) {
|
||||||
if (!defaultStore.state.showVisibilitySelectorOnBoost) {
|
if (!defaultStore.state.showVisibilitySelectorOnBoost && !forceMenu) {
|
||||||
renote(defaultStore.state.visibilityOnBoost);
|
renote(defaultStore.state.visibilityOnBoost);
|
||||||
} else {
|
} else {
|
||||||
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
||||||
|
|
|
@ -133,7 +133,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
class="_button"
|
class="_button"
|
||||||
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
||||||
@click.stop
|
@click.stop
|
||||||
@mousedown.prevent="renoted ? undoRenote(appearNote) : boostVisibility()"
|
@mousedown.prevent="renoted ? undoRenote(appearNote) : boostVisibility($event.shiftKey)"
|
||||||
>
|
>
|
||||||
<i class="ti ti-repeat"></i>
|
<i class="ti ti-repeat"></i>
|
||||||
<p v-if="appearNote.renoteCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
<p v-if="appearNote.renoteCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
||||||
|
@ -506,10 +506,10 @@ if (!props.mock) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function boostVisibility() {
|
function boostVisibility(forceMenu: boolean = false) {
|
||||||
if (renoting) return;
|
if (renoting) return;
|
||||||
|
|
||||||
if (!defaultStore.state.showVisibilitySelectorOnBoost) {
|
if (!defaultStore.state.showVisibilitySelectorOnBoost && !forceMenu) {
|
||||||
renote(defaultStore.state.visibilityOnBoost);
|
renote(defaultStore.state.visibilityOnBoost);
|
||||||
} else {
|
} else {
|
||||||
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
||||||
|
|
|
@ -148,7 +148,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
class="_button"
|
class="_button"
|
||||||
:class="$style.noteFooterButton"
|
:class="$style.noteFooterButton"
|
||||||
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
||||||
@mousedown.prevent="renoted ? undoRenote() : boostVisibility()"
|
@mousedown.prevent="renoted ? undoRenote() : boostVisibility($event.shiftKey)"
|
||||||
>
|
>
|
||||||
<i class="ti ti-repeat"></i>
|
<i class="ti ti-repeat"></i>
|
||||||
<p v-if="appearNote.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
<p v-if="appearNote.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ number(appearNote.renoteCount) }}</p>
|
||||||
|
@ -484,10 +484,10 @@ useTooltip(quoteButton, async (showing) => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
function boostVisibility() {
|
function boostVisibility(forceMenu: boolean = false) {
|
||||||
if (renoting) return;
|
if (renoting) return;
|
||||||
|
|
||||||
if (!defaultStore.state.showVisibilitySelectorOnBoost) {
|
if (!defaultStore.state.showVisibilitySelectorOnBoost && !forceMenu) {
|
||||||
renote(defaultStore.state.visibilityOnBoost);
|
renote(defaultStore.state.visibilityOnBoost);
|
||||||
} else {
|
} else {
|
||||||
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
||||||
|
|
|
@ -39,7 +39,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
class="_button"
|
class="_button"
|
||||||
:class="$style.noteFooterButton"
|
:class="$style.noteFooterButton"
|
||||||
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
:style="renoted ? 'color: var(--MI_THEME-accent) !important;' : ''"
|
||||||
@mousedown="renoted ? undoRenote() : boostVisibility()"
|
@mousedown="renoted ? undoRenote() : boostVisibility($event.shiftKey)"
|
||||||
>
|
>
|
||||||
<i class="ph-rocket-launch ph-bold ph-lg"></i>
|
<i class="ph-rocket-launch ph-bold ph-lg"></i>
|
||||||
<p v-if="note.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ note.renoteCount }}</p>
|
<p v-if="note.renoteCount > 0" :class="$style.noteFooterButtonCount">{{ note.renoteCount }}</p>
|
||||||
|
@ -299,8 +299,8 @@ watch(() => props.expandAllCws, (expandAllCws) => {
|
||||||
if (expandAllCws !== showContent.value) showContent.value = expandAllCws;
|
if (expandAllCws !== showContent.value) showContent.value = expandAllCws;
|
||||||
});
|
});
|
||||||
|
|
||||||
function boostVisibility() {
|
function boostVisibility(forceMenu: boolean = false) {
|
||||||
if (!defaultStore.state.showVisibilitySelectorOnBoost) {
|
if (!defaultStore.state.showVisibilitySelectorOnBoost && !forceMenu) {
|
||||||
renote(defaultStore.state.visibilityOnBoost);
|
renote(defaultStore.state.visibilityOnBoost);
|
||||||
} else {
|
} else {
|
||||||
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
os.popupMenu(boostMenuItems(appearNote, renote), renoteButton.value);
|
||||||
|
|
Loading…
Add table
Reference in a new issue