此页面由社区从英文翻译而来。了解更多并加入 MDN Web Docs 社区。

View in English Always switch to English

<mn>

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since ⁨2023年1月⁩.

<mn> MathML 元素表示一个数字字面量,通常是一个可能包含分隔符(点号或逗号)的数字序列。然而,也允许在其中包含任意文本,该文本实际上是一个数字量,例如“eleven”。

属性

该元素接受全局 MathML 属性

示例

html
<math display="block">
  <mn>0</mn>
</math>

<math display="block">
  <mn>1.337</mn>
</math>

<math display="block">
  <mn>twelve</mn>
</math>

<math display="block">
  <mn>XVI</mn>
</math>

<math display="block">
  <mn>2e10</mn>
</math>

规范

Specification
MathML Core
# number-mn

浏览器兼容性