Phenomenon
The lang attribute on a contenteditable region does not affect the spellcheck language in Safari. Spellcheck always uses the browserโs default language, regardless of the lang attribute value.
Reproduction example
- Create a contenteditable div with
lang="fr"andspellcheck="true". - Type French text.
- Observe whether spellcheck uses French dictionary.
Observed behavior
- In Safari on macOS, the
langattribute does not affect spellcheck. - Spellcheck always uses the browserโs default language.
- Multi-language content cannot be properly spellchecked.
Expected behavior
- The
langattribute should control the spellcheck language. - Spellcheck should use the appropriate dictionary for the specified language.
- Multi-language content should be properly supported.