me when the

This commit is contained in:
ThatOneCalculator 2022-11-09 20:44:43 -08:00
parent c331d23b3f
commit 2589ca1a3b
2 changed files with 10 additions and 4 deletions

View file

@ -1,6 +1,6 @@
{
"name": "calckey",
"version": "12.119.0-calc.12.4",
"version": "12.119.0-calc.12.5",
"codename": "aqua",
"repository": {
"type": "git",

View file

@ -6,7 +6,7 @@
</MkTab>
<div v-if="origin === 'local'">
<template v-if="tag == null">
<MkFolder v-if="pinnedUsersList.length > 0" class="_gap" persist-key="explore-pinned-users">
<MkFolder v-show="thereArePinnedUsers" class="_gap" persist-key="explore-pinned-users">
<template #header><i class="ph-bookmark-simple-bold ph-lg ph-fw ph-lg" style="margin-right: 0.5em;"></i>{{ i18n.ts.pinnedUsers }}</template>
<XUserList :pagination="pinnedUsers"/>
</MkFolder>
@ -75,11 +75,16 @@ let origin = $ref('local');
let tagsEl = $ref<InstanceType<typeof MkFolder>>();
let tagsLocal = $ref([]);
let tagsRemote = $ref([]);
let thereArePinnedUsers = $ref(false);
watch(() => props.tag, () => {
if (tagsEl) tagsEl.toggleContent(props.tag == null);
});
watch(() => pinnedUsersList, () => {
if (pinnedUsersList?.length > 0) thereArePinnedUsers = true;
});
const tagUsers = $computed(() => ({
endpoint: 'hashtags/users' as const,
limit: 30,
@ -90,8 +95,9 @@ const tagUsers = $computed(() => ({
},
}));
const pinnedUsersList = os.api('pinned-users');
console.log(pinnedUsersList);
const pinnedUsersList = await os.api('pinned-users');
if (pinnedUsersList?.length > 0) { thereArePinnedUsers = true; }
const pinnedUsers = { endpoint: 'pinned-users' };
const popularUsers = { endpoint: 'users', limit: 10, noPaging: true, params: {