Skip to content

Commit

Permalink
🐛 revert: force native spell check until Electron issue is fixed (#464)…
Browse files Browse the repository at this point in the history
… (#472)

Signed-off-by: Marc Nuri <[email protected]>
  • Loading branch information
manusa authored Jan 8, 2025
1 parent 87eb1f5 commit 1adea9f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 11 deletions.
4 changes: 0 additions & 4 deletions src/settings/settings.spell-check.browser.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,6 @@ export const SpellCheckPane = ({dispatch, state}) => {
checked=${useNative}
onClick=${toggleProperty({dispatch, property: 'useNativeSpellChecker'})}
/>
<div data-testid='settings-todo-native-spell-check' style=${{'font-size': '1.1rem', 'padding-left': '0.5rem'}}>
<p>NOTE: Currently, the Native Spell Checker is <strong>always</strong> used due to a bug in Electron:</p>
<p><a href='https://github.com/electron/electron/issues/44336'>electron/issues/44336</a></p>
</div>
<${Card.Divider} />
<div class='settings__dictionaries'>${
Object.entries(dictionaries(state))
Expand Down
8 changes: 1 addition & 7 deletions src/spell-check/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,7 @@ const getAvailableNativeDictionaries = () =>
const handleGetMisspelled = async (_event, words) =>
fakeRendererWorker.webContents.executeJavaScript(`getMisspelled(${JSON.stringify(words)})`);

const getUseNativeSpellChecker = () => {
// eslint-disable-next-line no-warning-comments
// TODO: always use native spellcheck until there's a fix for
// https://github.com/electron/electron/issues/44336
return true;
// return loadSettings().useNativeSpellChecker;
};
const getUseNativeSpellChecker = () => loadSettings().useNativeSpellChecker;

const getEnabledDictionaries = () => loadSettings().enabledDictionaries;

Expand Down

0 comments on commit 1adea9f

Please sign in to comment.