mirror of
https://git.joinfirefish.org/firefish/firefish.git
synced 2024-05-19 07:51:11 +02:00
chore (client): remove unnecessary non-null assertions
This commit is contained in:
parent
a49f9c33ef
commit
c6d0fe52d2
|
@ -8,7 +8,7 @@
|
||||||
<i :class="icon('ph-dots-three-outline')"></i>
|
<i :class="icon('ph-dots-three-outline')"></i>
|
||||||
</button>
|
</button>
|
||||||
<button
|
<button
|
||||||
v-if="!hideFollowButton && isSignedIn(me) && me!.id != user.id"
|
v-if="!hideFollowButton && isSignedIn(me) && me.id != user.id"
|
||||||
v-tooltip="full ? null : `${state} ${user.name || user.username}`"
|
v-tooltip="full ? null : `${state} ${user.name || user.username}`"
|
||||||
class="kpoogebi _button follow-button"
|
class="kpoogebi _button follow-button"
|
||||||
:class="{
|
:class="{
|
||||||
|
|
|
@ -53,7 +53,7 @@ const url = `/${canonical}`;
|
||||||
const isMe =
|
const isMe =
|
||||||
isSignedIn(me) &&
|
isSignedIn(me) &&
|
||||||
`@${props.username}@${toUnicode(props.host)}`.toLowerCase() ===
|
`@${props.username}@${toUnicode(props.host)}`.toLowerCase() ===
|
||||||
`@${me!.username}@${toUnicode(localHost)}`.toLowerCase();
|
`@${me.username}@${toUnicode(localHost)}`.toLowerCase();
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|
|
@ -370,7 +370,7 @@ const reactButton = ref<HTMLElement | null>(null);
|
||||||
const appearNote = computed(() =>
|
const appearNote = computed(() =>
|
||||||
isRenote ? (note.value.renote as NoteType) : note.value,
|
isRenote ? (note.value.renote as NoteType) : note.value,
|
||||||
);
|
);
|
||||||
const isMyRenote = isSignedIn(me) && me!.id === note.value.userId;
|
const isMyRenote = isSignedIn(me) && me.id === note.value.userId;
|
||||||
// const showContent = ref(false);
|
// const showContent = ref(false);
|
||||||
const isDeleted = ref(false);
|
const isDeleted = ref(false);
|
||||||
const muted = ref(
|
const muted = ref(
|
||||||
|
|
|
@ -77,7 +77,7 @@ const hasRenotedBefore = ref(false);
|
||||||
if (isSignedIn(me)) {
|
if (isSignedIn(me)) {
|
||||||
os.api("notes/renotes", {
|
os.api("notes/renotes", {
|
||||||
noteId: props.note.id,
|
noteId: props.note.id,
|
||||||
userId: me!.id,
|
userId: me.id,
|
||||||
limit: 1,
|
limit: 1,
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
hasRenotedBefore.value = res.length > 0;
|
hasRenotedBefore.value = res.length > 0;
|
||||||
|
|
|
@ -59,7 +59,7 @@
|
||||||
<div class="other">
|
<div class="other">
|
||||||
<button
|
<button
|
||||||
v-if="
|
v-if="
|
||||||
isSignedIn(me) && me!.id === post.user.id
|
isSignedIn(me) && me.id === post.user.id
|
||||||
"
|
"
|
||||||
v-tooltip="i18n.ts.toEdit"
|
v-tooltip="i18n.ts.toEdit"
|
||||||
v-click-anime
|
v-click-anime
|
||||||
|
@ -105,7 +105,7 @@
|
||||||
<MkAcct :user="post.user" />
|
<MkAcct :user="post.user" />
|
||||||
</div>
|
</div>
|
||||||
<MkFollowButton
|
<MkFollowButton
|
||||||
v-if="!isSignedIn(me) || me!.id != post.user.id"
|
v-if="!isSignedIn(me) || me.id != post.user.id"
|
||||||
:user="post.user"
|
:user="post.user"
|
||||||
:inline="true"
|
:inline="true"
|
||||||
:transparent="false"
|
:transparent="false"
|
||||||
|
|
Loading…
Reference in a new issue