Require mpv plugin in first-run setup

This commit is contained in:
2026-04-02 23:49:57 -07:00
parent 85e3aa4c6b
commit 8b9ac99f3d
9 changed files with 58 additions and 57 deletions

View File

@@ -2238,18 +2238,21 @@ const openFirstRunSetupWindowHandler = createOpenFirstRunSetupWindowHandler({
firstRunSetupMessage = snapshot.message;
return;
}
if (submission.action === 'skip-plugin') {
await firstRunSetupService.skipPluginInstall();
firstRunSetupMessage = 'mpv plugin installation skipped.';
return;
}
const snapshot = await firstRunSetupService.markSetupCompleted();
if (snapshot.state.status === 'completed') {
firstRunSetupMessage = null;
return { closeWindow: true };
}
firstRunSetupMessage = 'Install at least one Yomitan dictionary before finishing setup.';
if (snapshot.pluginStatus !== 'installed') {
firstRunSetupMessage = 'Install the mpv plugin before finishing setup.';
return;
}
if (!snapshot.externalYomitanConfigured && snapshot.dictionaryCount < 1) {
firstRunSetupMessage = 'Install at least one Yomitan dictionary before finishing setup.';
return;
}
firstRunSetupMessage = 'Finish setup requires the mpv plugin and Yomitan dictionaries.';
return;
},
markSetupInProgress: async () => {