adopted-ember-addons / adopted-ember-addons/ember-changeset-validations

Feature Request: Public API for getDescriptionFor

未关闭
#136 2 条评论 3 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
JavaScript
星标
215
派生
98
PR 合并指标
30 天内没有已合并 PR

描述

In my app, the propertyName for the input does not always map to the displayed label; this would be even more common in localised products.

For example:

```
{{spanishProperty}}

{{#if (get changeset.error property)}}


    {{#each (get (get changeset.error property) "validation") as |message|}}
  • {{message}}

  • {{/each}}


{{/if}}
```

While it is possible to change the messages hash per language, the hardcoded `{description}` just takes the propertyName and normalises it.

Would it be possible to allow the `app/utils/messages.js` file to be overridden, in order to allow more complex names for the `{description}` placeholder?

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。