Uploaded image for project: 'Runtime'
  1. Runtime
  2. RUNTIME-4251

I18nTransformer should consider default value as default value

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • 4.9.3, 4.10.0, 4.8.16
    • None
    • None
    • None
    • 1 - Middle term
    • 2 - Normal

      Currently, we force the i18n values from XSL to be i18n keys. As the standard implementation (https://cocoon.apache.org/2.1/userdocs/i18nTransformer.html#Translation+with+param+substitution) we should accept static messages too.

      For example, this code:

      <i18n:translate>
          <i18n:text>My lovely text: \{myText}</i18n:text>
          <i18n:param name="myText">It's so nice!</i18n:param>
      </i18n:translate>

      Display this:

      null:My lovely text: It's so nice!

      (null can be a real catalog depending of the context)

      Also, note that the i18n:text value between tags is the default value, not the key (https://cocoon.apache.org/2.1/userdocs/i18nTransformer.html#i18n%3Atext).

      In our case, we force the default value to be a key.
      Only the key should be a key, not the default value.

            Unassigned Unassigned
            bmaurel Bérénice Maurel
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: