mirror of
https://codeberg.org/yeentown/barkey.git
synced 2025-07-08 13:04:34 +00:00
use responsive gaps between note toolbar items
This commit is contained in:
parent
dc35731589
commit
4d024d1165
8 changed files with 27 additions and 151 deletions
|
@ -113,7 +113,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
<MkA :to="`/notes/${appearNote.id}/reactions`" :class="[$style.reactionOmitted]">{{ i18n.ts.more }}</MkA>
|
<MkA :to="`/notes/${appearNote.id}/reactions`" :class="[$style.reactionOmitted]">{{ i18n.ts.more }}</MkA>
|
||||||
</template>
|
</template>
|
||||||
</MkReactionsViewer>
|
</MkReactionsViewer>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<button :class="$style.footerButton" class="_button" @click.stop @click="reply()">
|
<button :class="$style.footerButton" class="_button" @click.stop @click="reply()">
|
||||||
<i class="ti ti-arrow-back-up"></i>
|
<i class="ti ti-arrow-back-up"></i>
|
||||||
<p v-if="appearNote.repliesCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.repliesCount) }}</p>
|
<p v-if="appearNote.repliesCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.repliesCount) }}</p>
|
||||||
|
@ -1203,10 +1203,6 @@ function emitUpdReaction(emoji: string, delta: number) {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--MI_THEME-fgHighlighted);
|
color: var(--MI_THEME-fgHighlighted);
|
||||||
}
|
}
|
||||||
|
@ -1290,25 +1286,7 @@ function emitUpdReaction(emoji: string, delta: number) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 400px) {
|
|
||||||
.root:not(.showActionsOnlyHover) {
|
|
||||||
.footerButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.2em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@container (max-width: 350px) {
|
@container (max-width: 350px) {
|
||||||
.root:not(.showActionsOnlyHover) {
|
|
||||||
.footerButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.colorBar {
|
.colorBar {
|
||||||
top: 6px;
|
top: 6px;
|
||||||
left: 6px;
|
left: 6px;
|
||||||
|
|
|
@ -118,7 +118,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
</div>
|
</div>
|
||||||
<MkA v-if="appearNote.channel && !inChannel" :class="$style.channel" :to="`/channels/${appearNote.channel.id}`"><i class="ti ti-device-tv"></i> {{ appearNote.channel.name }}</MkA>
|
<MkA v-if="appearNote.channel && !inChannel" :class="$style.channel" :to="`/channels/${appearNote.channel.id}`"><i class="ti ti-device-tv"></i> {{ appearNote.channel.name }}</MkA>
|
||||||
</div>
|
</div>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<div :class="$style.noteFooterInfo">
|
<div :class="$style.noteFooterInfo">
|
||||||
<div v-if="appearNote.updatedAt">
|
<div v-if="appearNote.updatedAt">
|
||||||
{{ i18n.ts.edited }}: <MkTime :time="appearNote.updatedAt" mode="detail"/>
|
{{ i18n.ts.edited }}: <MkTime :time="appearNote.updatedAt" mode="detail"/>
|
||||||
|
@ -1083,10 +1083,6 @@ function animatedMFM() {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--MI_THEME-fgHighlighted);
|
color: var(--MI_THEME-fgHighlighted);
|
||||||
}
|
}
|
||||||
|
@ -1169,14 +1165,6 @@ function animatedMFM() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 350px) {
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@container (max-width: 300px) {
|
@container (max-width: 300px) {
|
||||||
.root {
|
.root {
|
||||||
font-size: 0.825em;
|
font-size: 0.825em;
|
||||||
|
@ -1186,12 +1174,6 @@ function animatedMFM() {
|
||||||
width: 50px;
|
width: 50px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.muted {
|
.muted {
|
||||||
|
|
|
@ -19,7 +19,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
<MkSubNoteContent :class="$style.text" :note="note" :translating="translating" :translation="translation" :expandAllCws="props.expandAllCws"/>
|
<MkSubNoteContent :class="$style.text" :note="note" :translating="translating" :translation="translation" :expandAllCws="props.expandAllCws"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<MkReactionsViewer ref="reactionsViewer" :note="note"/>
|
<MkReactionsViewer ref="reactionsViewer" :note="note"/>
|
||||||
<button class="_button" :class="$style.noteFooterButton" @click="reply()">
|
<button class="_button" :class="$style.noteFooterButton" @click="reply()">
|
||||||
<i class="ph-arrow-u-up-left ph-bold ph-lg"></i>
|
<i class="ph-arrow-u-up-left ph-bold ph-lg"></i>
|
||||||
|
@ -469,23 +469,11 @@ if (props.detail) {
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--MI_THEME-fgHighlighted);
|
color: var(--MI_THEME-fgHighlighted);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 400px) {
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.7em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.noteFooterButtonCount {
|
.noteFooterButtonCount {
|
||||||
display: inline;
|
display: inline;
|
||||||
margin: 0 0 0 8px;
|
margin: 0 0 0 8px;
|
||||||
|
|
|
@ -114,7 +114,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
<MkA :to="`/notes/${appearNote.id}/reactions`" :class="[$style.reactionOmitted]">{{ i18n.ts.more }}</MkA>
|
<MkA :to="`/notes/${appearNote.id}/reactions`" :class="[$style.reactionOmitted]">{{ i18n.ts.more }}</MkA>
|
||||||
</template>
|
</template>
|
||||||
</MkReactionsViewer>
|
</MkReactionsViewer>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<button :class="$style.footerButton" class="_button" @click.stop @click="reply()">
|
<button :class="$style.footerButton" class="_button" @click.stop @click="reply()">
|
||||||
<i class="ti ti-arrow-back-up"></i>
|
<i class="ti ti-arrow-back-up"></i>
|
||||||
<p v-if="appearNote.repliesCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.repliesCount) }}</p>
|
<p v-if="appearNote.repliesCount > 0" :class="$style.footerButtonCount">{{ number(appearNote.repliesCount) }}</p>
|
||||||
|
@ -947,10 +947,6 @@ function emitUpdReaction(emoji: string, delta: number) {
|
||||||
|
|
||||||
.footerButton {
|
.footerButton {
|
||||||
font-size: 90%;
|
font-size: 90%;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1238,10 +1234,6 @@ function emitUpdReaction(emoji: string, delta: number) {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--MI_THEME-fgHighlighted);
|
color: var(--MI_THEME-fgHighlighted);
|
||||||
}
|
}
|
||||||
|
@ -1358,25 +1350,7 @@ function emitUpdReaction(emoji: string, delta: number) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 400px) {
|
|
||||||
.root:not(.showActionsOnlyHover) {
|
|
||||||
.footerButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.2em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@container (max-width: 350px) {
|
@container (max-width: 350px) {
|
||||||
.root:not(.showActionsOnlyHover) {
|
|
||||||
.footerButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.colorBar {
|
.colorBar {
|
||||||
top: 6px;
|
top: 6px;
|
||||||
left: 6px;
|
left: 6px;
|
||||||
|
@ -1385,16 +1359,6 @@ function emitUpdReaction(emoji: string, delta: number) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 300px) {
|
|
||||||
.root:not(.showActionsOnlyHover) {
|
|
||||||
.footerButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@container (max-width: 250px) {
|
@container (max-width: 250px) {
|
||||||
.quoteNote {
|
.quoteNote {
|
||||||
padding: 12px;
|
padding: 12px;
|
||||||
|
|
|
@ -132,7 +132,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
</MkA>
|
</MkA>
|
||||||
</div>
|
</div>
|
||||||
<MkReactionsViewer v-if="appearNote.reactionAcceptance !== 'likeOnly'" ref="reactionsViewer" style="margin-top: 6px;" :note="appearNote"/>
|
<MkReactionsViewer v-if="appearNote.reactionAcceptance !== 'likeOnly'" ref="reactionsViewer" style="margin-top: 6px;" :note="appearNote"/>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<button class="_button" :class="$style.noteFooterButton" @click="reply()">
|
<button class="_button" :class="$style.noteFooterButton" @click="reply()">
|
||||||
<i class="ti ti-arrow-back-up"></i>
|
<i class="ti ti-arrow-back-up"></i>
|
||||||
<p v-if="appearNote.repliesCount > 0" :class="$style.noteFooterButtonCount">{{ number(appearNote.repliesCount) }}</p>
|
<p v-if="appearNote.repliesCount > 0" :class="$style.noteFooterButtonCount">{{ number(appearNote.repliesCount) }}</p>
|
||||||
|
@ -1141,10 +1141,6 @@ onUnmounted(() => {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--MI_THEME-fgHighlighted);
|
color: var(--MI_THEME-fgHighlighted);
|
||||||
}
|
}
|
||||||
|
@ -1234,14 +1230,6 @@ onUnmounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 350px) {
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@container (max-width: 300px) {
|
@container (max-width: 300px) {
|
||||||
.root {
|
.root {
|
||||||
font-size: 0.825em;
|
font-size: 0.825em;
|
||||||
|
@ -1251,12 +1239,6 @@ onUnmounted(() => {
|
||||||
width: 50px;
|
width: 50px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.avatar {
|
.avatar {
|
||||||
|
|
|
@ -28,7 +28,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<MkReactionsViewer ref="reactionsViewer" :note="note"/>
|
<MkReactionsViewer ref="reactionsViewer" :note="note"/>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<button class="_button" :class="$style.noteFooterButton" @click="reply()">
|
<button class="_button" :class="$style.noteFooterButton" @click="reply()">
|
||||||
<i class="ph-arrow-u-up-left ph-bold ph-lg"></i>
|
<i class="ph-arrow-u-up-left ph-bold ph-lg"></i>
|
||||||
<p v-if="note.repliesCount > 0" :class="$style.noteFooterButtonCount">{{ note.repliesCount }}</p>
|
<p v-if="note.repliesCount > 0" :class="$style.noteFooterButtonCount">{{ note.repliesCount }}</p>
|
||||||
|
@ -559,14 +559,6 @@ if (props.detail) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 400px) {
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.7em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.noteFooterButtonCount {
|
.noteFooterButtonCount {
|
||||||
display: inline;
|
display: inline;
|
||||||
margin: 0 0 0 8px;
|
margin: 0 0 0 8px;
|
||||||
|
|
|
@ -52,7 +52,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
</div>
|
</div>
|
||||||
<MkA v-if="appearNote.channel && !inChannel" :class="$style.channel" :to="`/channels/${appearNote.channel.id}`"><i class="ph-television ph-bold ph-lg"></i> {{ appearNote.channel.name }}</MkA>
|
<MkA v-if="appearNote.channel && !inChannel" :class="$style.channel" :to="`/channels/${appearNote.channel.id}`"><i class="ph-television ph-bold ph-lg"></i> {{ appearNote.channel.name }}</MkA>
|
||||||
</div>
|
</div>
|
||||||
<footer :class="$style.footer">
|
<footer :class="$style.footer" class="_gaps _h_gaps">
|
||||||
<div :class="$style.noteFooterInfo">
|
<div :class="$style.noteFooterInfo">
|
||||||
<MkTime :time="appearNote.createdAt" mode="detail"/>
|
<MkTime :time="appearNote.createdAt" mode="detail"/>
|
||||||
</div>
|
</div>
|
||||||
|
@ -280,23 +280,11 @@ const showTicker = (prefer.s.instanceTicker === 'always') || (prefer.s.instanceT
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--MI_THEME-fgHighlighted);
|
color: var(--MI_THEME-fgHighlighted);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@container (max-width: 350px) {
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@container (max-width: 500px) {
|
@container (max-width: 500px) {
|
||||||
.root {
|
.root {
|
||||||
font-size: 0.9em;
|
font-size: 0.9em;
|
||||||
|
@ -323,11 +311,5 @@ const showTicker = (prefer.s.instanceTicker === 'always') || (prefer.s.instanceT
|
||||||
width: 50px;
|
width: 50px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.noteFooterButton {
|
|
||||||
&:not(:last-child) {
|
|
||||||
margin-right: 0.1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -428,6 +428,14 @@ rt {
|
||||||
gap: var(--MI-margin);
|
gap: var(--MI-margin);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use with _gaps, _gaps_m, or _gaps_s.
|
||||||
|
* Place the other class *first*!
|
||||||
|
*/
|
||||||
|
._h_gaps {
|
||||||
|
flex-direction: row;
|
||||||
|
}
|
||||||
|
|
||||||
._buttons {
|
._buttons {
|
||||||
display: flex;
|
display: flex;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
|
|
Loading…
Add table
Reference in a new issue