CSS open-quote shows 1 quotation mark

后端 未结 4 2160
情话喂你
情话喂你 2021-02-08 14:02

I\'m using the following CSS to add open quotes before a paragraph:

blockquote {
  padding: 22px;
  quotes: \"\\201C\"\"\\201D\"\"\\2018\"\"\\2019\";
  font-size         


        
4条回答
  •  广开言路
    2021-02-08 14:46

    In blockquote:after you set the content to no-close-quote:

    blockquote:after {
      content: no-close-quote
    }
    

    Here is a snippet:

      blockquote {
          padding: 22px;
          quotes: "\201C""\201D""\2018""\2019";
          font-size: 15px;
      }
      blockquote:before {
          color: #111;
          content: open-quote;
          font-size: 4em;
          line-height: 0;
          vertical-align: -0.4em;
      }
      
      /* Add this */
      blockquote:after {
          content: no-close-quote;
      }

    Blockquote 1

    Blockquote 2

提交回复
热议问题