Merge pull request 'develop' (#9098) from develop into main
Reviewed-on: https://codeberg.org/thatonecalculator/calckey/pulls/9098
This commit is contained in:
commit
95ffd19742
|
@ -180,7 +180,7 @@ pm2 start "NODE_ENV=production yarn start" --name Calckey
|
||||||
### 🐋 Prebuilt Docker image
|
### 🐋 Prebuilt Docker image
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
docker pull thatonecalculator:calckey
|
docker pull thatonecalculator/calckey
|
||||||
docker up -d
|
docker up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "calckey",
|
"name": "calckey",
|
||||||
"version": "12.119.0-calc.12",
|
"version": "12.119.0-calc.12.5",
|
||||||
"codename": "aqua",
|
"codename": "aqua",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|
|
@ -2,14 +2,14 @@ import { IsNull } from 'typeorm';
|
||||||
import { Users } from '@/models/index.js';
|
import { Users } from '@/models/index.js';
|
||||||
import { fetchMeta } from '@/misc/fetch-meta.js';
|
import { fetchMeta } from '@/misc/fetch-meta.js';
|
||||||
import * as Acct from '@/misc/acct.js';
|
import * as Acct from '@/misc/acct.js';
|
||||||
import { User } from '@/models/entities/user.js';
|
import type { User } from '@/models/entities/user.js';
|
||||||
import define from '../define.js';
|
import define from '../define.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
tags: ['users'],
|
tags: ['users'],
|
||||||
|
|
||||||
requireCredential: false,
|
requireCredential: false,
|
||||||
requireCredentialPrivateMode: true,
|
requireCredentialPrivateMode: false,
|
||||||
|
|
||||||
res: {
|
res: {
|
||||||
type: 'array',
|
type: 'array',
|
||||||
|
|
|
@ -169,12 +169,12 @@ const menuDef = $computed(() => [{
|
||||||
to: '/admin/security',
|
to: '/admin/security',
|
||||||
active: currentPage?.route.name === 'security',
|
active: currentPage?.route.name === 'security',
|
||||||
}, {
|
}, {
|
||||||
icon: 'ph-planet-bold ph-lg',
|
icon: 'ph-flow-arrow-bold ph-lg',
|
||||||
text: i18n.ts.relays,
|
text: i18n.ts.relays,
|
||||||
to: '/admin/relays',
|
to: '/admin/relays',
|
||||||
active: currentPage?.route.name === 'relays',
|
active: currentPage?.route.name === 'relays',
|
||||||
}, {
|
}, {
|
||||||
icon: 'ph-share-network-bold ph-lg',
|
icon: 'ph-plug-bold ph-lg',
|
||||||
text: i18n.ts.integration,
|
text: i18n.ts.integration,
|
||||||
to: '/admin/integrations',
|
to: '/admin/integrations',
|
||||||
active: currentPage?.route.name === 'integrations',
|
active: currentPage?.route.name === 'integrations',
|
||||||
|
|
|
@ -1,27 +1,29 @@
|
||||||
<template><MkStickyContainer>
|
<template>
|
||||||
|
<MkStickyContainer>
|
||||||
<template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template>
|
<template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template>
|
||||||
<MkSpacer :content-max="700" :margin-min="16" :margin-max="32">
|
<MkSpacer :content-max="700" :margin-min="16" :margin-max="32">
|
||||||
<FormSuspense :p="init">
|
<FormSuspense :p="init">
|
||||||
<FormFolder class="_formBlock">
|
<FormFolder class="_formBlock">
|
||||||
<template #icon><i class="fab fa-twitter"></i></template>
|
<template #icon><i class="fab fa-twitter"></i></template>
|
||||||
<template #label>Twitter</template>
|
<template #label>Twitter</template>
|
||||||
<template #suffix>{{ enableTwitterIntegration ? i18n.ts.enabled : i18n.ts.disabled }}</template>
|
<template #suffix>{{ enableTwitterIntegration ? i18n.ts.enabled : i18n.ts.disabled }}</template>
|
||||||
<XTwitter/>
|
<XTwitter/>
|
||||||
</FormFolder>
|
</FormFolder>
|
||||||
<FormFolder class="_formBlock">
|
<FormFolder class="_formBlock">
|
||||||
<template #icon><i class="fab fa-github"></i></template>
|
<template #icon><i class="fab fa-github"></i></template>
|
||||||
<template #label>GitHub</template>
|
<template #label>GitHub</template>
|
||||||
<template #suffix>{{ enableGithubIntegration ? i18n.ts.enabled : i18n.ts.disabled }}</template>
|
<template #suffix>{{ enableGithubIntegration ? i18n.ts.enabled : i18n.ts.disabled }}</template>
|
||||||
<XGithub/>
|
<XGithub/>
|
||||||
</FormFolder>
|
</FormFolder>
|
||||||
<FormFolder class="_formBlock">
|
<FormFolder class="_formBlock">
|
||||||
<template #icon><i class="fab fa-discord"></i></template>
|
<template #icon><i class="fab fa-discord"></i></template>
|
||||||
<template #label>Discord</template>
|
<template #label>Discord</template>
|
||||||
<template #suffix>{{ enableDiscordIntegration ? i18n.ts.enabled : i18n.ts.disabled }}</template>
|
<template #suffix>{{ enableDiscordIntegration ? i18n.ts.enabled : i18n.ts.disabled }}</template>
|
||||||
<XDiscord/>
|
<XDiscord/>
|
||||||
</FormFolder>
|
</FormFolder>
|
||||||
</FormSuspense>
|
</FormSuspense>
|
||||||
</MkSpacer></MkStickyContainer>
|
</MkSpacer>
|
||||||
|
</MkStickyContainer>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
|
@ -52,6 +54,6 @@ const headerTabs = $computed(() => []);
|
||||||
|
|
||||||
definePageMetadata({
|
definePageMetadata({
|
||||||
title: i18n.ts.integration,
|
title: i18n.ts.integration,
|
||||||
icon: 'ph-share-network-bold ph-lg',
|
icon: 'ph-plug-bold ph-lg',
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -76,7 +76,7 @@ const headerTabs = $computed(() => []);
|
||||||
|
|
||||||
definePageMetadata({
|
definePageMetadata({
|
||||||
title: i18n.ts.relays,
|
title: i18n.ts.relays,
|
||||||
icon: 'ph-planet-bold ph-lg',
|
icon: 'ph-flow-arrow-bold ph-lg',
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
</MkTab>
|
</MkTab>
|
||||||
<div v-if="origin === 'local'">
|
<div v-if="origin === 'local'">
|
||||||
<template v-if="tag == null">
|
<template v-if="tag == null">
|
||||||
<MkFolder v-if="pinnedUsers.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>
|
<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"/>
|
<XUserList :pagination="pinnedUsers"/>
|
||||||
</MkFolder>
|
</MkFolder>
|
||||||
|
@ -75,11 +75,16 @@ let origin = $ref('local');
|
||||||
let tagsEl = $ref<InstanceType<typeof MkFolder>>();
|
let tagsEl = $ref<InstanceType<typeof MkFolder>>();
|
||||||
let tagsLocal = $ref([]);
|
let tagsLocal = $ref([]);
|
||||||
let tagsRemote = $ref([]);
|
let tagsRemote = $ref([]);
|
||||||
|
let thereArePinnedUsers = $ref(false);
|
||||||
|
|
||||||
watch(() => props.tag, () => {
|
watch(() => props.tag, () => {
|
||||||
if (tagsEl) tagsEl.toggleContent(props.tag == null);
|
if (tagsEl) tagsEl.toggleContent(props.tag == null);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
watch(() => pinnedUsersList, () => {
|
||||||
|
if (pinnedUsersList?.length > 0) thereArePinnedUsers = true;
|
||||||
|
});
|
||||||
|
|
||||||
const tagUsers = $computed(() => ({
|
const tagUsers = $computed(() => ({
|
||||||
endpoint: 'hashtags/users' as const,
|
endpoint: 'hashtags/users' as const,
|
||||||
limit: 30,
|
limit: 30,
|
||||||
|
@ -90,6 +95,10 @@ const tagUsers = $computed(() => ({
|
||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
const pinnedUsersList = await os.api('pinned-users');
|
||||||
|
|
||||||
|
if (pinnedUsersList?.length > 0) { thereArePinnedUsers = true; }
|
||||||
|
|
||||||
const pinnedUsers = { endpoint: 'pinned-users' };
|
const pinnedUsers = { endpoint: 'pinned-users' };
|
||||||
const popularUsers = { endpoint: 'users', limit: 10, noPaging: true, params: {
|
const popularUsers = { endpoint: 'users', limit: 10, noPaging: true, params: {
|
||||||
state: 'alive',
|
state: 'alive',
|
||||||
|
|
|
@ -266,7 +266,7 @@ export const defaultStore = markRaw(new Storage('base', {
|
||||||
showAdminUpdates: {
|
showAdminUpdates: {
|
||||||
where: 'account',
|
where: 'account',
|
||||||
default: true,
|
default: true,
|
||||||
}
|
},
|
||||||
}));
|
}));
|
||||||
|
|
||||||
// TODO: 他のタブと永続化されたstateを同期
|
// TODO: 他のタブと永続化されたstateを同期
|
||||||
|
|
Loading…
Reference in New Issue