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

Javascript localization module shows doubled single quotes twice instead of processing them using the translation messages rules

    XMLWordPrintable

Details

    • Unknown
    • N/A
    • N/A

    Description

      Reproduction steps:

      • Import the attached XAR
      • Open the imported page

      Expected result:

      • It should display:
        0 with 'quotes'
        
        10 with 'quotes'
        

      Obtained result:

      • it displays:
        0 with 'quotes'
        
        10 with ''quotes''
        

      — Previous description —
      For example, for the like UI for XWIKI-18545, we have the following translation (in french):

      like.likers.link.zero={0} J''aime
      

      (the doubled single quote is needed because it's a parametrized message and this is the format for such messages).

      When used from velocity, it displays as "0 J'aime" (correctly), when fetched from javascript using the xwiki-l10n API added by XWIKI-18973, it shows "0 J''aime" (incorrectly).

      Attachments

        Issue Links

          Activity

            People

              surli Simon Urli
              lucaa Anca Luca
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: