Merge remote-tracking branch 'misskey-original/develop' into develop

This commit is contained in:
mattyatea 2023-10-22 12:48:46 +09:00
commit 212986a3a8
6 changed files with 35 additions and 9 deletions

View File

@ -12,10 +12,11 @@
-->
## 2023.x.x (unreleased)
## 2023.11.0 (unreleased)
### General
-
- Feat: アイコンデコレーション機能
- Enhance: すでにフォローしたすべての人の返信をTLに追加できるように
## Client
- Feat: プラグイン・テーマを外部サイトから直接インストールできるようになりました
@ -23,7 +24,7 @@
https://misskey-hub.net/docs/advanced/publish-on-your-website.html
### Server
-
- Fix: リストTLに自分のフォロワー限定投稿が含まれない問題を修正
## 2023.10.2
@ -35,7 +36,6 @@
- Enhance: フォロー/フォロー解除したときに過去分のHTLにも含まれる投稿が反映されるように
- Enhance: ローカリゼーションの更新
- Enhance: 依存関係の更新
- Enhance: すでにフォローしたすべての人の返信をTLに追加できるように
### Client
- Enhance: TLの返信表示オプションを記憶するように

View File

@ -868,7 +868,7 @@ export class NoteCreateService implements OnApplicationShutdown {
if (note.visibility === 'followers') {
// TODO: 重そうだから何とかしたい Set 使う?
userListMemberships = userListMemberships.filter(x => followings.some(f => f.followerId === x.userListUserId));
userListMemberships = userListMemberships.filter(x => x.userListUserId === user.id || followings.some(f => f.followerId === x.userListUserId));
}
// TODO: あまりにも数が多いと redisPipeline.exec に失敗する(理由は不明)ため、3万件程度を目安に分割して実行するようにする

View File

@ -26,7 +26,12 @@ export function convertSchemaToOpenApiSchema(schema: Schema) {
if (schema.allOf) res.allOf = schema.allOf.map(convertSchemaToOpenApiSchema);
if (schema.ref) {
res.$ref = `#/components/schemas/${schema.ref}`;
const $ref = `#/components/schemas/${schema.ref}`;
if (schema.nullable || schema.optional) {
res.allOf = [{ $ref }];
} else {
res.$ref = $ref;
}
}
return res;

View File

@ -947,6 +947,22 @@ describe('Timelines', () => {
assert.strictEqual(res.body.find((note: any) => note.id === bobNote.id).text, 'hi');
});
test.concurrent('リスインしている自分の visibility: followers なノートが含まれる', async () => {
const [alice] = await Promise.all([signup(), signup()]);
const list = await api('/users/lists/create', { name: 'list' }, alice).then(res => res.body);
await api('/users/lists/push', { listId: list.id, userId: alice.id }, alice);
await sleep(1000);
const aliceNote = await post(alice, { text: 'hi', visibility: 'followers' });
await waitForPushToTl();
const res = await api('/notes/user-list-timeline', { listId: list.id }, alice);
assert.strictEqual(res.body.some((note: any) => note.id === aliceNote.id), true);
assert.strictEqual(res.body.find((note: any) => note.id === aliceNote.id).text, 'hi');
});
test.concurrent('リスインしているユーザーのチャンネルノートが含まれない', async () => {
const [alice, bob] = await Promise.all([signup(), signup()]);

View File

@ -294,6 +294,7 @@ const patrons = [
'美少女JKぐーちゃん',
'てば',
'たっくん',
'SHO SEKIGUCHI',
];
let thereIsTreasure = $ref($i && !claimedAchievements.includes('foundTreasure'));

View File

@ -94,7 +94,7 @@ SPDX-License-Identifier: AGPL-3.0-only
:class="[$style.avatarDecoration, { [$style.avatarDecorationActive]: $i.avatarDecorations.some(x => x.id === avatarDecoration.id) }]"
@click="toggleDecoration(avatarDecoration)"
>
<div :class="$style.avatarDecorationName">{{ avatarDecoration.name }}</div>
<div :class="$style.avatarDecorationName"><MkCondensedLine :minScale="2 / 3">{{ avatarDecoration.name }}</MkCondensedLine></div>
<MkAvatar style="width: 64px; height: 64px;" :user="$i" :decoration="avatarDecoration.url"/>
</div>
</div>
@ -377,13 +377,17 @@ definePageMetadata({
.avatarDecoration {
cursor: pointer;
padding: 16px 16px 24px 16px;
padding: 16px 16px 28px 16px;
border: solid 2px var(--divider);
border-radius: 8px;
text-align: center;
font-size: 90%;
overflow: clip;
contain: content;
}
.avatarDecorationActive {
background-color: var(--accentedBg);
border-color: var(--accent);
}
@ -391,6 +395,6 @@ definePageMetadata({
position: relative;
z-index: 10;
font-weight: bold;
margin-bottom: 16px;
margin-bottom: 20px;
}
</style>