30秒学会 CSS 片段 · 2023年9月8日

30秒学会 CSS 片段 – Stylized quotation marks

Customizes the style of inline quotation marks.

  • Use the quotes property to customize the characters used for the opening and closing quotes of a <q> element.

预览

Do or do not, there is no try. – Yoda



HTML

<p>
  <q>Do or do not, there is no try.</q> – Yoda
</p>

CSS

q {
  quotes: "“" "”";
}

翻译自:https://www.30secondsofcode.org/css/s/stylized-quotation-marks