Skip to content

wallets: Make link labels translatable #1154

@xaur

Description

@xaur

Currently link labels at https://decred.org/wallets/ are hardcoded in the wallets.yml file and cannot be translated, e.g. see https://decred.org/zh/wallets/

An idea how it could work is change wallets.yml to reference label keys from transifex_catalogs/en.json and move English strings to the latter. wallets.yml would change from:

  links:
    - title: Download and release notes
      url: https://github.com/crypto-power/cryptopower/releases/tag/release-v1.0.0
    - title: Website
      url: https://cryptopower.dev

to

  links:
    - label_key: wallets_cryptopower_release
      url: https://github.com/crypto-power/cryptopower/releases/tag/release-v1.0.0
    - label_key: wallets_cryptopower_website
      url: https://cryptopower.dev

and en.json would gain keys like:

{
  "wallets_cryptopower_release": "Download and release notes",
  "wallets_cryptopower_website": "Website"
}

@jholdstock is this feasible in Hugo?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions