70 likes | 250 Views
VIVO-652. VIVO language strings must be included in the theme. Problem. Currently, all properties used in VIVO templates are specified in the theme file A theme whose templates use no language properties still needs a large all.properties file. Challenges.
E N D
VIVO-652 VIVO language strings must be included in the theme.
Problem • Currently, all properties used in VIVO templates are specified in the theme file • A theme whose templates use no language properties still needs a large all.properties file.
Challenges • Overriding is per-property, not per-file. • Must be a clear hierarchy: which file overrides which others: • Must adjust to languages: • all.properties • all_en.properties • all_en_US.properties • all_en_CA.properties
Challenges • Want to keep open the possibility of named files: • visual.properties • "${i18n('visual').visualization_label}"
Hierarchy by filename • Vitro: all.properties • VIVO: all-vivo.properties • VIVO-cornell: all-vivo-cornell.properties • Theme: wilma/all.properties • Other possibilities: • all.properties, all2.properties, all3.properties • 3 overrides 1?
Hierarchy by location • Examples: • Vitro: i18n/all.properties • VIVO: i18n/vivo/all.properties • VIVO-Cornell: i18n/vivo/cornell/all.properties • Theme: wilma/i18n/all.properties • Rule: • Child directory are higher in the hierarchy than parent directory • Lower is higher?
Separate hierarchies • Examples: • Vitro: i18n/all.properties • VIVO: i18n/vivo.properties • VIVO-Cornell: i18n/cornell.properties • Theme: wilma/i18n/theme.properties • Usage: specify which file: • title="${i18n('vivo').menu_support}"