feat(plugins): add batch install update and uninstall actions
This commit is contained in:
13 files changed
+988
-138
No files matched your search
@@ -0,0 +1,24 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { createI18n } from "vue-i18n";
|
||||
import az from "@/i18n/locales/az";
|
||||
import en from "@/i18n/locales/en";
|
||||
import es from "@/i18n/locales/es";
|
||||
import itLocale from "@/i18n/locales/it";
|
||||
import ja from "@/i18n/locales/ja";
|
||||
import ko from "@/i18n/locales/ko";
|
||||
import ptBR from "@/i18n/locales/pt-BR";
|
||||
import tr from "@/i18n/locales/tr";
|
||||
import zhCN from "@/i18n/locales/zh-CN";
|
||||
import zhTW from "@/i18n/locales/zh-TW";
|
||||
|
||||
describe("plugin batch messages", () => {
|
||||
it.each(Object.entries({ az, en, es, it: itLocale, ja, ko, "pt-BR": ptBR, tr, "zh-CN": zhCN, "zh-TW": zhTW }))("interpolates source conflicts and refresh errors in %s", (locale, messages) => {
|
||||
const pluginPlatform = messages.pluginPlatform as Pick<typeof en.pluginPlatform, "batchDuplicateSources" | "batchRefreshFailed">;
|
||||
const i18n = createI18n({ legacy: false, locale, messages: { [locale]: { pluginPlatform } } });
|
||||
expect(pluginPlatform.batchDuplicateSources.match(/\{[^}]+\}/g)).toEqual(["{names}"]);
|
||||
expect(pluginPlatform.batchRefreshFailed.match(/\{[^}]+\}/g)).toEqual(["{error}"]);
|
||||
expect(i18n.global.t("pluginPlatform.batchDuplicateSources", { names: "example.plugin" })).toContain("example.plugin");
|
||||
expect(i18n.global.t("pluginPlatform.batchRefreshFailed", { error: "refresh offline" })).toContain("refresh offline");
|
||||
i18n.dispose();
|
||||
});
|
||||
});
|
||||
@@ -257,6 +257,17 @@ export default {
|
||||
uninstallConfirm: "Uninstall {name}?",
|
||||
uninstallSuccess: "Uninstalled {name}",
|
||||
installSuccess: "Installed {name} {version}",
|
||||
batchManage: "Batch",
|
||||
batchDone: "Done",
|
||||
batchSelected: "{count} selected",
|
||||
batchSelectAllUpdatable: "Select all updatable",
|
||||
batchInstallUpdate: "Install / update",
|
||||
batchUninstall: "Uninstall selected",
|
||||
batchUninstallConfirm: "Uninstall {count} plugin(s)?\n{names}",
|
||||
batchSummary: "Done: {success} succeeded",
|
||||
batchSummaryWithFailures: "Done: {success} succeeded, {failed} failed ({names})",
|
||||
batchDuplicateSources: "Multiple sources selected for: {names}. Keep only one source selected per plugin before continuing.",
|
||||
batchRefreshFailed: "The batch has finished, but the plugin list could not be refreshed: {error}",
|
||||
selectConnectionProvider: "Select a connection provider first",
|
||||
connectionProvider: "Connection provider",
|
||||
newConnection: "New",
|
||||
|
||||
@@ -251,6 +251,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "¿Desinstalar {name}?",
|
||||
uninstallSuccess: "Se desinstaló {name}",
|
||||
installSuccess: "Se instaló {name} {version}",
|
||||
batchManage: "Lote",
|
||||
batchDone: "Listo",
|
||||
batchSelected: "{count} seleccionados",
|
||||
batchSelectAllUpdatable: "Seleccionar todos actualizables",
|
||||
batchInstallUpdate: "Instalar / actualizar",
|
||||
batchUninstall: "Desinstalar seleccionados",
|
||||
batchUninstallConfirm: "¿Desinstalar {count} complemento(s)? {names}",
|
||||
batchSummary: "Listo: {success} con éxito",
|
||||
batchSummaryWithFailures: "Listo: {success} con éxito, {failed} con error ({names})",
|
||||
batchDuplicateSources: "Se seleccionaron varias fuentes para: {names}. Mantén seleccionada solo una fuente por complemento antes de continuar.",
|
||||
batchRefreshFailed: "El lote ha finalizado, pero no se pudo actualizar la lista de complementos: {error}",
|
||||
selectConnectionProvider: "Selecciona primero un proveedor de conexión",
|
||||
connectionProvider: "Proveedor de conexión",
|
||||
newConnection: "Nueva",
|
||||
|
||||
@@ -250,6 +250,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "Disinstallare {name}?",
|
||||
uninstallSuccess: "{name} disinstallato",
|
||||
installSuccess: "Installato {name} {version}",
|
||||
batchManage: "Batch",
|
||||
batchDone: "Fine",
|
||||
batchSelected: "{count} selezionati",
|
||||
batchSelectAllUpdatable: "Seleziona tutti aggiornabili",
|
||||
batchInstallUpdate: "Installa / aggiorna",
|
||||
batchUninstall: "Disinstalla selezionati",
|
||||
batchUninstallConfirm: "Disinstallare {count} plug-in? {names}",
|
||||
batchSummary: "Completato: {success} riusciti",
|
||||
batchSummaryWithFailures: "Completato: {success} riusciti, {failed} falliti ({names})",
|
||||
batchDuplicateSources: "Sono state selezionate più fonti per: {names}. Mantieni selezionata una sola fonte per plug-in prima di continuare.",
|
||||
batchRefreshFailed: "Le operazioni in gruppo sono terminate, ma non è stato possibile aggiornare l'elenco dei plug-in: {error}",
|
||||
selectConnectionProvider: "Seleziona prima un provider di connessione",
|
||||
connectionProvider: "Provider di connessione",
|
||||
newConnection: "Nuova",
|
||||
|
||||
@@ -251,6 +251,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "{name} をアンインストールしますか?",
|
||||
uninstallSuccess: "{name} をアンインストールしました",
|
||||
installSuccess: "{name} {version} をインストールしました",
|
||||
batchManage: "一括",
|
||||
batchDone: "完了",
|
||||
batchSelected: "{count} 件選択中",
|
||||
batchSelectAllUpdatable: "更新可能をすべて選択",
|
||||
batchInstallUpdate: "インストール / 更新",
|
||||
batchUninstall: "選択をアンインストール",
|
||||
batchUninstallConfirm: "{count} 個のプラグインをアンインストールしますか? {names}",
|
||||
batchSummary: "完了:{success} 件成功",
|
||||
batchSummaryWithFailures: "完了:{success} 件成功、{failed} 件失敗({names})",
|
||||
batchDuplicateSources: "複数の配布元が選択されています:{names}。続行する前に、各プラグインの配布元を1つだけ選択してください。",
|
||||
batchRefreshFailed: "一括処理は完了しましたが、プラグイン一覧を更新できませんでした:{error}",
|
||||
selectConnectionProvider: "先に接続プロバイダーを選択してください",
|
||||
connectionProvider: "接続プロバイダー",
|
||||
newConnection: "新規",
|
||||
|
||||
@@ -259,6 +259,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "{name}을 제거하시겠습니까?",
|
||||
uninstallSuccess: "{name}을 제거했습니다",
|
||||
installSuccess: "{name} {version}을 설치했습니다",
|
||||
batchManage: "일괄",
|
||||
batchDone: "완료",
|
||||
batchSelected: "{count}개 선택됨",
|
||||
batchSelectAllUpdatable: "업데이트 가능한 항목 모두 선택",
|
||||
batchInstallUpdate: "설치 / 업데이트",
|
||||
batchUninstall: "선택 항목 제거",
|
||||
batchUninstallConfirm: "{count}개 플러그인을 제거할까요? {names}",
|
||||
batchSummary: "완료: {success}개 성공",
|
||||
batchSummaryWithFailures: "완료: {success}개 성공, {failed}개 실패 ({names})",
|
||||
batchDuplicateSources: "여러 소스가 선택되었습니다: {names}. 계속하기 전에 플러그인마다 하나의 소스만 선택해 주세요.",
|
||||
batchRefreshFailed: "일괄 작업은 완료되었지만 플러그인 목록을 새로 고칠 수 없습니다: {error}",
|
||||
selectConnectionProvider: "먼저 연결 제공자를 선택하세요",
|
||||
connectionProvider: "연결 제공자",
|
||||
newConnection: "새 연결",
|
||||
|
||||
@@ -251,6 +251,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "Desinstalar {name}?",
|
||||
uninstallSuccess: "{name} desinstalado",
|
||||
installSuccess: "{name} {version} instalado",
|
||||
batchManage: "Lote",
|
||||
batchDone: "Concluído",
|
||||
batchSelected: "{count} selecionados",
|
||||
batchSelectAllUpdatable: "Selecionar todos atualizáveis",
|
||||
batchInstallUpdate: "Instalar / atualizar",
|
||||
batchUninstall: "Desinstalar selecionados",
|
||||
batchUninstallConfirm: "Desinstalar {count} plugin(s)? {names}",
|
||||
batchSummary: "Concluído: {success} com sucesso",
|
||||
batchSummaryWithFailures: "Concluído: {success} com sucesso, {failed} com falha ({names})",
|
||||
batchDuplicateSources: "Várias fontes selecionadas para: {names}. Mantenha apenas uma fonte selecionada por plugin antes de continuar.",
|
||||
batchRefreshFailed: "O lote foi concluído, mas não foi possível atualizar a lista de plugins: {error}",
|
||||
selectConnectionProvider: "Selecione primeiro um provedor de conexão",
|
||||
connectionProvider: "Provedor de conexão",
|
||||
newConnection: "Nova",
|
||||
|
||||
@@ -173,6 +173,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "卸载 {name}?",
|
||||
uninstallSuccess: "已卸载 {name}",
|
||||
installSuccess: "已安装 {name} {version}",
|
||||
batchManage: "批量管理",
|
||||
batchDone: "完成",
|
||||
batchSelected: "已选 {count} 项",
|
||||
batchSelectAllUpdatable: "全选可更新",
|
||||
batchInstallUpdate: "安装 / 更新",
|
||||
batchUninstall: "卸载所选",
|
||||
batchUninstallConfirm: "确定卸载 {count} 个插件?\n{names}",
|
||||
batchSummary: "完成:成功 {success} 个",
|
||||
batchSummaryWithFailures: "完成:成功 {success} 个,失败 {failed} 个({names})",
|
||||
batchDuplicateSources: "以下插件选择了多个来源:{names}。请为每个插件仅保留一个来源后继续。",
|
||||
batchRefreshFailed: "批量操作已完成,但插件列表刷新失败:{error}",
|
||||
selectConnectionProvider: "请先选择连接提供者",
|
||||
connectionProvider: "连接提供者",
|
||||
newConnection: "新建",
|
||||
|
||||
@@ -251,6 +251,17 @@ export default withEnglishFallback({
|
||||
uninstallConfirm: "解除安裝 {name}?",
|
||||
uninstallSuccess: "已解除安裝 {name}",
|
||||
installSuccess: "已安裝 {name} {version}",
|
||||
batchManage: "批次管理",
|
||||
batchDone: "完成",
|
||||
batchSelected: "已選 {count} 項",
|
||||
batchSelectAllUpdatable: "全選可更新",
|
||||
batchInstallUpdate: "安裝 / 更新",
|
||||
batchUninstall: "解除安裝所選",
|
||||
batchUninstallConfirm: "確定解除安裝 {count} 個外掛? {names}",
|
||||
batchSummary: "完成:成功 {success} 個",
|
||||
batchSummaryWithFailures: "完成:成功 {success} 個,失敗 {failed} 個({names})",
|
||||
batchDuplicateSources: "以下外掛選取了多個來源:{names}。請為每個外掛僅保留一個來源後繼續。",
|
||||
batchRefreshFailed: "批次操作已完成,但外掛清單重新整理失敗:{error}",
|
||||
selectConnectionProvider: "請先選擇連線提供者",
|
||||
connectionProvider: "連線提供者",
|
||||
newConnection: "新增",
|
||||
|
||||
Reference in new issue
Block a user