diff --git a/locales/index.d.ts b/locales/index.d.ts index 1439931512..4b7e0705cf 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -4215,6 +4215,10 @@ export interface Locale extends ILocale { * CWを維持する */ "keepCw": string; + /** + * %sが検索語句に置き換えられます + */ + "searchEngineDescription": string; /** * Pub/Subのアカウント */ diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 1211a2b6d6..e955f6a450 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -1045,6 +1045,7 @@ usernameInfo: "サーバー上であなたのアカウントを一意に識別 aiChanMode: "藍モード" devMode: "開発者モード" keepCw: "CWを維持する" +searchEngineDescription: "%sが検索語句に置き換えられます" pubSub: "Pub/Subのアカウント" lastCommunication: "直近の通信" resolved: "解決済み" diff --git a/packages/frontend/src/components/MkGoogle.vue b/packages/frontend/src/components/MkGoogle.vue index da7bcde4d8..21bc007c37 100644 --- a/packages/frontend/src/components/MkGoogle.vue +++ b/packages/frontend/src/components/MkGoogle.vue @@ -12,7 +12,12 @@ SPDX-License-Identifier: AGPL-3.0-only diff --git a/packages/frontend/src/pages/settings/general.vue b/packages/frontend/src/pages/settings/general.vue index 293c912004..417d054353 100644 --- a/packages/frontend/src/pages/settings/general.vue +++ b/packages/frontend/src/pages/settings/general.vue @@ -60,6 +60,10 @@ SPDX-License-Identifier: AGPL-3.0-only {{ i18n.ts.noNyaization }} CherryPick {{ i18n.ts.showMultipleRenoteWarning }} yojo-art + + + + @@ -161,6 +165,7 @@ import FormSection from '@/components/form/section.vue'; import FormLink from '@/components/form/link.vue'; import MkLink from '@/components/MkLink.vue'; import MkInfo from '@/components/MkInfo.vue'; +import MkInput from '@/components/MkInput.vue'; import { defaultStore } from '@/store.js'; import * as os from '@/os.js'; import { misskeyApi } from '@/scripts/misskey-api.js'; @@ -201,6 +206,7 @@ const useAutoTranslate = computed(defaultStore.makeGetterSetter('useAutoTranslat const welcomeBackToast = computed(defaultStore.makeGetterSetter('welcomeBackToast')); const disableNyaize = computed(defaultStore.makeGetterSetter('disableNyaize')); const checkMultipleRenote = computed(defaultStore.makeGetterSetter('checkMultipleRenote')); +const searchEngine = computed(defaultStore.makeGetterSetter('searchEngine')); watch(lang, () => { miLocalStorage.setItem('lang', lang.value as string); diff --git a/packages/frontend/src/pages/settings/preferences-backups.vue b/packages/frontend/src/pages/settings/preferences-backups.vue index 7e53f2a3a7..ce0be8da04 100644 --- a/packages/frontend/src/pages/settings/preferences-backups.vue +++ b/packages/frontend/src/pages/settings/preferences-backups.vue @@ -191,6 +191,10 @@ const defaultStoreSaveKeys: (keyof typeof defaultStore['state'])[] = [ 'showMoreButtonInNoteFooter', 'selectReaction', // #endregion CherryPick + // #region yojo-art + 'checkMultipleRenote', + 'searchEngine', + // #endregion yojo-art ]; const coldDeviceStorageSaveKeys: (keyof typeof ColdDeviceStorage.default)[] = [ 'lightTheme', diff --git a/packages/frontend/src/store.ts b/packages/frontend/src/store.ts index f2b3d35c94..9e486c4072 100644 --- a/packages/frontend/src/store.ts +++ b/packages/frontend/src/store.ts @@ -153,6 +153,10 @@ export const defaultStore = markRaw(new Storage('base', { where: 'account', default: [] as string[], }, + searchEngine: { + where: 'account', + default: 'https://www.google.com/search?q=%s', + }, menu: { where: 'deviceAccount',