feat(config): reorganize settings window and move annotation colors to subtitleStyle

- Reorganize Configuration window into Appearance, Behavior, Anki, Input, and Integration sections
- Add AnkiConnect-backed deck, note-type, and field pickers in the Anki section
- Add click-to-learn keybinding controls
- Move known-word and N+1 highlight colors to subtitleStyle.knownWordColor / subtitleStyle.nPlusOneColor; legacy ankiConnect.knownWords.color and ankiConnect.nPlusOne.nPlusOne keys still accepted with deprecation warnings
- Add deckNames, modelNames, modelFieldNames, and fieldNamesForDeck methods to AnkiConnectClient
- Mark discordPresence.presenceStyle as an enum in the config registry
This commit is contained in:
2026-05-17 02:10:16 -07:00
parent a54f03f0cd
commit 309ce6ef8f
44 changed files with 2152 additions and 321 deletions
+4 -4
View File
@@ -14,8 +14,8 @@ const fields: ConfigSettingsField[] = [
label: 'Pause on subtitle hover',
description: 'Pause while hovering subtitles.',
configPath: 'subtitleStyle.autoPauseVideoOnHover',
category: 'viewing',
section: 'Playback pause behavior',
category: 'behavior',
section: 'Playback Pause Behavior',
control: 'boolean',
defaultValue: true,
restartBehavior: 'hot-reload',
@@ -35,12 +35,12 @@ const fields: ConfigSettingsField[] = [
test('filterSettingsFields searches label, section, and config path', () => {
assert.deepEqual(
filterSettingsFields(fields, { category: 'viewing', query: 'hover' }).map(
filterSettingsFields(fields, { category: 'behavior', query: 'hover' }).map(
(field) => field.configPath,
),
['subtitleStyle.autoPauseVideoOnHover'],
);
assert.deepEqual(filterSettingsFields(fields, { category: 'viewing', query: 'anki' }), []);
assert.deepEqual(filterSettingsFields(fields, { category: 'behavior', query: 'anki' }), []);
});
test('settings draft tracks dirty set and emits save operations', () => {