fix(frontend): 個人宛てダイアログお知らせが即時表示されない問題 (#14260)
* fix(frontend): 個人向けお知らせが即時ダイアログで出ない問題 * Update CHANGELOG
This commit is contained in:
		
							parent
							
								
									615e60f25c
								
							
						
					
					
						commit
						54d0a46378
					
				
					 2 changed files with 9 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -43,6 +43,7 @@
 | 
			
		|||
  (Cherry-picked from https://activitypub.software/TransFem-org/Sharkey/-/merge_requests/574)
 | 
			
		||||
- Fix: Twitchの埋め込みが開けない問題を修正
 | 
			
		||||
- Fix: 子メニューの高さがウィンドウからはみ出ることがある問題を修正
 | 
			
		||||
- Fix: 個人宛てのダイアログ形式のお知らせが即時表示されない問題を修正
 | 
			
		||||
 | 
			
		||||
### Server
 | 
			
		||||
- Feat: レートリミット制限に引っかかったときに`Retry-After`ヘッダーを返すように (#13949)
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -5,6 +5,7 @@
 | 
			
		|||
 | 
			
		||||
import { createApp, defineAsyncComponent, markRaw } from 'vue';
 | 
			
		||||
import { common } from './common.js';
 | 
			
		||||
import type * as Misskey from 'misskey-js';
 | 
			
		||||
import { ui } from '@/config.js';
 | 
			
		||||
import { i18n } from '@/i18n.js';
 | 
			
		||||
import { alert, confirm, popup, post, toast } from '@/os.js';
 | 
			
		||||
| 
						 | 
				
			
			@ -113,7 +114,7 @@ export async function mainBoot() {
 | 
			
		|||
			});
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		stream.on('announcementCreated', (ev) => {
 | 
			
		||||
		function onAnnouncementCreated (ev: { announcement: Misskey.entities.Announcement }) {
 | 
			
		||||
			const announcement = ev.announcement;
 | 
			
		||||
			if (announcement.display === 'dialog') {
 | 
			
		||||
				const { dispose } = popup(defineAsyncComponent(() => import('@/components/MkAnnouncementDialog.vue')), {
 | 
			
		||||
| 
						 | 
				
			
			@ -122,7 +123,9 @@ export async function mainBoot() {
 | 
			
		|||
					closed: () => dispose(),
 | 
			
		||||
				});
 | 
			
		||||
			}
 | 
			
		||||
		});
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		stream.on('announcementCreated', onAnnouncementCreated);
 | 
			
		||||
 | 
			
		||||
		if ($i.isDeleted) {
 | 
			
		||||
			alert({
 | 
			
		||||
| 
						 | 
				
			
			@ -315,6 +318,9 @@ export async function mainBoot() {
 | 
			
		|||
			updateAccount({ hasUnreadAnnouncement: false });
 | 
			
		||||
		});
 | 
			
		||||
 | 
			
		||||
		// 個人宛てお知らせが発行されたとき
 | 
			
		||||
		main.on('announcementCreated', onAnnouncementCreated);
 | 
			
		||||
 | 
			
		||||
		// トークンが再生成されたとき
 | 
			
		||||
		// このままではMisskeyが利用できないので強制的にサインアウトさせる
 | 
			
		||||
		main.on('myTokenRegenerated', () => {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue