Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-1248

Strong XWiki syntax

    XMLWordPrintable

Details

    • Task
    • Resolution: Fixed
    • Minor
    • 1.3 M2
    • None
    • {Unused} Wiki features
    • None
    • Unit

    Description

      The strong wiki markup is triggered by placing a piece of text inside stars, like: *text*. This filter only works in single line mode.

      It generates markup specifying that the delimited text is strongly empahised; in XHTML the <strong> tag is used.

      Expected behavior:

      This is not * bold * => This is not * bold *
      This is not *bold * => This is not *bold *
      This is not * bold* => This is not * bold*
      This is *bold* => This is <strong>bold</strong>
      This is *a* letter bold => This is <strong>a</strong> letter bold
      This is *a* short bold* => This is <strong>a</strong> short bold*
      This is *all * bold* => This is <strong>all * bold</strong>
      This is *all *bold* => This is <strong>all *bold</strong>
      This is *one*bold* => This is <strong>one</strong>bold*
      *a* => <strong>a</strong>
      More *bolds* on a *line* => More <strong>bolds</strong> on a <strong>line</strong>
      The extra stars are **inside** => The extra stars are <strong>*inside*</strong>
      This*is*bold => This<strong>is</strong>bold
      *Eeny*meeny*miny*moe* => <strong>Eeny</strong>meeny<strong>miny</strong>moe*
      * Eeny*meeny*miny*moe* => ...<li>Eeny<strong>meeny</strong>miny<strong>moe</strong></li>...
      * list* item => ...<li>list* item</li>...
      * *list* item => ...<li><strong>list</strong> item</li>...
      This is a bold *** text => This is an bold <strong>*</strong> text
      This is a bold ****** text => This is an bold <strong>****</strong> text
      Ignore *things* inside <script> var x = m*n+n*n; </script> => Ignore <strong>things</strong> inside <script> var x = m*n+n*n; </script>
      Ignore <a href="/some*page*with*stars">attributes</a> => Ignore <a href="/some*page*with*stars">attributes</a>
      
      Multiline examples:
      This is not *not
      bold*
       =>
      This is not *not
      bold*
      
      <script>
      var s = "non *bold* text";
      </script>
      var s = "non *bold* text"; 
       =>
      <script>
      var s = "non *bold* text";
      </script>
      var s = "non <strong>bold</strong> text";
      

      Attachments

        Issue Links

          Activity

            People

              sdumitriu Sergiu Dumitriu
              sdumitriu Sergiu Dumitriu
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: