Skip to content

Document which BCP 47 lang tags activate which translation files #14418

@cderv

Description

@cderv

The language docs at https://quarto.org/docs/authoring/language.html state "IETF language tags (BCP 47 standard), like en or en-GB" and list supported languages as prose ("...Chinese, Czech, Danish..."). Nothing tells a user writing a Chinese document which of zh / zh-TW / zh-Hant / zh-Hans will activate which UI translation. Same issue for Serbian — we ship _language-sr-Latn.yml but docs don't mention it.

This ambiguity surfaced in #14409 where a user couldn't tell whether zh-Hant or zh-TW was the "right" tag for Quarto (answer: zh-TW for our full translations, zh-Hant only for Pandoc's side).

Suggestions

We could:

  • Add a table to the language docs listing each shipped translation file and the lang: values that activate it
  • Briefly explain the BCP 47 script-vs-region subtag distinction and note that both forms are valid — Quarto uses region subtags for Chinese (zh-TW) and Portuguese (pt-BR) but script subtags for Serbian (sr-Latn), reflecting contributed files
  • Note Quarto's subtag-prefix fallback (zh-TW loads zh + zh-TW; fr-CA would load fr + fr-CA if that file existed)

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationDoc improvements & quarto-web

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions