mirror of
				https://codeberg.org/yeentown/barkey.git
				synced 2025-11-04 15:34:13 +00:00 
			
		
		
		
	Merge branch 'develop' of https://github.com/misskey-dev/misskey into develop
This commit is contained in:
		
						commit
						bf01c1ee64
					
				
					 4 changed files with 80 additions and 55 deletions
				
			
		| 
						 | 
					@ -38,6 +38,7 @@
 | 
				
			||||||
- Enhance: プラグインを削除した際には、使用されていたアクセストークンも同時に削除されるようになりました
 | 
					- Enhance: プラグインを削除した際には、使用されていたアクセストークンも同時に削除されるようになりました
 | 
				
			||||||
- Enhance: プラグインで`Plugin:register_note_view_interruptor`を用いてnoteの代わりにnullを返却することでノートを非表示にできるようになりました
 | 
					- Enhance: プラグインで`Plugin:register_note_view_interruptor`を用いてnoteの代わりにnullを返却することでノートを非表示にできるようになりました
 | 
				
			||||||
- Enhance: AiScript関数`Mk:nyaize()`が追加されました
 | 
					- Enhance: AiScript関数`Mk:nyaize()`が追加されました
 | 
				
			||||||
 | 
					- Enhance: 情報→ツール はナビゲーションバーにツールとして独立した項目になりました
 | 
				
			||||||
- Enhance: その他細かなブラッシュアップ
 | 
					- Enhance: その他細かなブラッシュアップ
 | 
				
			||||||
- Fix: 投稿フォームでのユーザー変更がプレビューに反映されない問題を修正
 | 
					- Fix: 投稿フォームでのユーザー変更がプレビューに反映されない問題を修正
 | 
				
			||||||
- Fix: ユーザーページの ノート > ファイル付き タブにリプライが表示されてしまう
 | 
					- Fix: ユーザーページの ノート > ファイル付き タブにリプライが表示されてしまう
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -6,7 +6,7 @@
 | 
				
			||||||
import { computed, reactive } from 'vue';
 | 
					import { computed, reactive } from 'vue';
 | 
				
			||||||
import { $i } from '@/account.js';
 | 
					import { $i } from '@/account.js';
 | 
				
			||||||
import { miLocalStorage } from '@/local-storage.js';
 | 
					import { miLocalStorage } from '@/local-storage.js';
 | 
				
			||||||
import { openInstanceMenu } from '@/ui/_common_/common.js';
 | 
					import { openInstanceMenu, openToolsMenu } from '@/ui/_common_/common.js';
 | 
				
			||||||
import { lookup } from '@/scripts/lookup.js';
 | 
					import { lookup } from '@/scripts/lookup.js';
 | 
				
			||||||
import * as os from '@/os.js';
 | 
					import * as os from '@/os.js';
 | 
				
			||||||
import { i18n } from '@/i18n.js';
 | 
					import { i18n } from '@/i18n.js';
 | 
				
			||||||
| 
						 | 
					@ -142,6 +142,13 @@ export const navbarItemDef = reactive({
 | 
				
			||||||
			openInstanceMenu(ev);
 | 
								openInstanceMenu(ev);
 | 
				
			||||||
		},
 | 
							},
 | 
				
			||||||
	},
 | 
						},
 | 
				
			||||||
 | 
						tools: {
 | 
				
			||||||
 | 
							title: i18n.ts.tools,
 | 
				
			||||||
 | 
							icon: 'ti ti-tool',
 | 
				
			||||||
 | 
							action: (ev) => {
 | 
				
			||||||
 | 
								openToolsMenu(ev);
 | 
				
			||||||
 | 
							},
 | 
				
			||||||
 | 
						},
 | 
				
			||||||
	reload: {
 | 
						reload: {
 | 
				
			||||||
		title: i18n.ts.reload,
 | 
							title: i18n.ts.reload,
 | 
				
			||||||
		icon: 'ti ti-refresh',
 | 
							icon: 'ti ti-refresh',
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -140,15 +140,9 @@ function focus(): void {
 | 
				
			||||||
	tlComponent.focus();
 | 
						tlComponent.focus();
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const headerActions = $computed(() => [
 | 
					const headerActions = $computed(() => {
 | 
				
			||||||
	...[deviceKind === 'desktop' ? {
 | 
						const tmp = [
 | 
				
			||||||
		icon: 'ti ti-refresh',
 | 
							{
 | 
				
			||||||
		text: i18n.ts.reload,
 | 
					 | 
				
			||||||
		handler: (ev) => {
 | 
					 | 
				
			||||||
			console.log('called');
 | 
					 | 
				
			||||||
			tlComponent.reloadTimeline();
 | 
					 | 
				
			||||||
		},
 | 
					 | 
				
			||||||
	} : {}], {
 | 
					 | 
				
			||||||
			icon: 'ti ti-dots',
 | 
								icon: 'ti ti-dots',
 | 
				
			||||||
			text: i18n.ts.options,
 | 
								text: i18n.ts.options,
 | 
				
			||||||
			handler: (ev) => {
 | 
								handler: (ev) => {
 | 
				
			||||||
| 
						 | 
					@ -168,8 +162,20 @@ const headerActions = $computed(() => [
 | 
				
			||||||
					ref: $$(onlyFiles),
 | 
										ref: $$(onlyFiles),
 | 
				
			||||||
				}], ev.currentTarget ?? ev.target);
 | 
									}], ev.currentTarget ?? ev.target);
 | 
				
			||||||
			},
 | 
								},
 | 
				
			||||||
 | 
							},
 | 
				
			||||||
 | 
						];
 | 
				
			||||||
 | 
						if (deviceKind === 'desktop') {
 | 
				
			||||||
 | 
							tmp.unshift({
 | 
				
			||||||
 | 
								icon: 'ti ti-refresh',
 | 
				
			||||||
 | 
								text: i18n.ts.reload,
 | 
				
			||||||
 | 
								handler: (ev: Event) => {
 | 
				
			||||||
 | 
									console.log('called');
 | 
				
			||||||
 | 
									tlComponent.reloadTimeline();
 | 
				
			||||||
 | 
								},
 | 
				
			||||||
 | 
							});
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
]);
 | 
						return tmp;
 | 
				
			||||||
 | 
					});
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const headerTabs = $computed(() => [...(defaultStore.reactiveState.pinnedUserLists.value.map(l => ({
 | 
					const headerTabs = $computed(() => [...(defaultStore.reactiveState.pinnedUserLists.value.map(l => ({
 | 
				
			||||||
	key: 'list:' + l.id,
 | 
						key: 'list:' + l.id,
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -3,12 +3,42 @@
 | 
				
			||||||
 * SPDX-License-Identifier: AGPL-3.0-only
 | 
					 * SPDX-License-Identifier: AGPL-3.0-only
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					import type { MenuItem } from '@/types/menu.js';
 | 
				
			||||||
import * as os from '@/os.js';
 | 
					import * as os from '@/os.js';
 | 
				
			||||||
import { instance } from '@/instance.js';
 | 
					import { instance } from '@/instance.js';
 | 
				
			||||||
import { host } from '@/config.js';
 | 
					import { host } from '@/config.js';
 | 
				
			||||||
import { i18n } from '@/i18n.js';
 | 
					import { i18n } from '@/i18n.js';
 | 
				
			||||||
import { $i } from '@/account.js';
 | 
					import { $i } from '@/account.js';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function toolsMenuItems(): MenuItem[] {
 | 
				
			||||||
 | 
						return [{
 | 
				
			||||||
 | 
							type: 'link',
 | 
				
			||||||
 | 
							to: '/scratchpad',
 | 
				
			||||||
 | 
							text: i18n.ts.scratchpad,
 | 
				
			||||||
 | 
							icon: 'ti ti-terminal-2',
 | 
				
			||||||
 | 
						}, {
 | 
				
			||||||
 | 
							type: 'link',
 | 
				
			||||||
 | 
							to: '/api-console',
 | 
				
			||||||
 | 
							text: 'API Console',
 | 
				
			||||||
 | 
							icon: 'ti ti-terminal-2',
 | 
				
			||||||
 | 
						}, {
 | 
				
			||||||
 | 
							type: 'link',
 | 
				
			||||||
 | 
							to: '/clicker',
 | 
				
			||||||
 | 
							text: '🍪👈',
 | 
				
			||||||
 | 
							icon: 'ti ti-cookie',
 | 
				
			||||||
 | 
						}, ($i && ($i.isAdmin || $i.policies.canManageCustomEmojis)) ? {
 | 
				
			||||||
 | 
							type: 'link',
 | 
				
			||||||
 | 
							to: '/custom-emojis-manager',
 | 
				
			||||||
 | 
							text: i18n.ts.manageCustomEmojis,
 | 
				
			||||||
 | 
							icon: 'ti ti-icons',
 | 
				
			||||||
 | 
						} : undefined, ($i && ($i.isAdmin || $i.policies.canManageAvatarDecorations)) ? {
 | 
				
			||||||
 | 
							type: 'link',
 | 
				
			||||||
 | 
							to: '/avatar-decorations',
 | 
				
			||||||
 | 
							text: i18n.ts.manageAvatarDecorations,
 | 
				
			||||||
 | 
							icon: 'ti ti-sparkles',
 | 
				
			||||||
 | 
						} : undefined];
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
export function openInstanceMenu(ev: MouseEvent) {
 | 
					export function openInstanceMenu(ev: MouseEvent) {
 | 
				
			||||||
	os.popupMenu([{
 | 
						os.popupMenu([{
 | 
				
			||||||
		text: instance.name ?? host,
 | 
							text: instance.name ?? host,
 | 
				
			||||||
| 
						 | 
					@ -47,32 +77,7 @@ export function openInstanceMenu(ev: MouseEvent) {
 | 
				
			||||||
		type: 'parent',
 | 
							type: 'parent',
 | 
				
			||||||
		text: i18n.ts.tools,
 | 
							text: i18n.ts.tools,
 | 
				
			||||||
		icon: 'ti ti-tool',
 | 
							icon: 'ti ti-tool',
 | 
				
			||||||
		children: [{
 | 
							children: toolsMenuItems(),
 | 
				
			||||||
			type: 'link',
 | 
					 | 
				
			||||||
			to: '/scratchpad',
 | 
					 | 
				
			||||||
			text: i18n.ts.scratchpad,
 | 
					 | 
				
			||||||
			icon: 'ti ti-terminal-2',
 | 
					 | 
				
			||||||
		}, {
 | 
					 | 
				
			||||||
			type: 'link',
 | 
					 | 
				
			||||||
			to: '/api-console',
 | 
					 | 
				
			||||||
			text: 'API Console',
 | 
					 | 
				
			||||||
			icon: 'ti ti-terminal-2',
 | 
					 | 
				
			||||||
		}, {
 | 
					 | 
				
			||||||
			type: 'link',
 | 
					 | 
				
			||||||
			to: '/clicker',
 | 
					 | 
				
			||||||
			text: '🍪👈',
 | 
					 | 
				
			||||||
			icon: 'ti ti-cookie',
 | 
					 | 
				
			||||||
		}, ($i && ($i.isAdmin || $i.policies.canManageCustomEmojis)) ? {
 | 
					 | 
				
			||||||
			type: 'link',
 | 
					 | 
				
			||||||
			to: '/custom-emojis-manager',
 | 
					 | 
				
			||||||
			text: i18n.ts.manageCustomEmojis,
 | 
					 | 
				
			||||||
			icon: 'ti ti-icons',
 | 
					 | 
				
			||||||
		} : undefined, ($i && ($i.isAdmin || $i.policies.canManageAvatarDecorations)) ? {
 | 
					 | 
				
			||||||
			type: 'link',
 | 
					 | 
				
			||||||
			to: '/avatar-decorations',
 | 
					 | 
				
			||||||
			text: i18n.ts.manageAvatarDecorations,
 | 
					 | 
				
			||||||
			icon: 'ti ti-sparkles',
 | 
					 | 
				
			||||||
		} : undefined],
 | 
					 | 
				
			||||||
	}, null, (instance.impressumUrl) ? {
 | 
						}, null, (instance.impressumUrl) ? {
 | 
				
			||||||
		text: i18n.ts.impressum,
 | 
							text: i18n.ts.impressum,
 | 
				
			||||||
		icon: 'ti ti-file-invoice',
 | 
							icon: 'ti ti-file-invoice',
 | 
				
			||||||
| 
						 | 
					@ -105,3 +110,9 @@ export function openInstanceMenu(ev: MouseEvent) {
 | 
				
			||||||
		align: 'left',
 | 
							align: 'left',
 | 
				
			||||||
	});
 | 
						});
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					export function openToolsMenu(ev: MouseEvent) {
 | 
				
			||||||
 | 
						os.popupMenu(toolsMenuItems(), ev.currentTarget ?? ev.target, {
 | 
				
			||||||
 | 
							align: 'left',
 | 
				
			||||||
 | 
						});
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		
		Reference in a new issue