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

Feature Request: Public API for getDescriptionFor

オープン
#136 コメント 2 件 リアクション 3 件 担当者 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 を短くまとめたダイジェスト。