CSS

::spelling-error

*拼写错误

这是一种实验技术

由于该技术的规格不稳定,请查看各种浏览器的兼容性表格以供使用。另外请注意,随着规范的变化,实验技术的语法和行为在未来版本的浏览器中可能会发生变化。

::spelling-errorCSS 伪元素表示浏览器已经被标记为不正确拼写的文本片段。

::spelling-error { color: red; }

只有一小部分CSS属性可以::spelling-error在其选择器中使用:

  • color

  • background-color

  • cursor

  • text-emphasis-color

  • text-shadow

  • outline和它的远郊

  • text-decoration及其相关性质

规范

SpecificationStatusComment
CSS Pseudo-Elements Level 4The definition of '::spelling-error' in that specification.Working DraftInitial definition

浏览器兼容性

FeatureChromeFirefox (Gecko)Internet ExplorerOperaSafari
Basic support?????

FeatureAndroidChrome for AndroidFirefox Mobile (Gecko)IE MobileOpera MobileSafari Mobile
Basic support??????