Sha256: 07edc1dcd0c588258dad9a7b6d534d58b13485c1dd5ddab80c4715d1e24720ee

Contents?: true

Size: 948 Bytes

Versions: 1

Compression:

Stored size: 948 Bytes

Contents

<%
js_configs = {
  icons_path: image_path("decidim/icons.svg")
}
character_messages = {
  "charactersAtLeast": {
    one: t("forms.length_validator.minimum.one", count: "%count%"),
    other: t("forms.length_validator.minimum.other", count: "%count%")
  },
  "charactersLeft": {
    one: t("decidim.components.add_comment_form.remaining_characters_1", count: "%count%"),
    other: t("decidim.components.add_comment_form.remaining_characters", count: "%count%")
  }
}
external_link_messages = {
  "externalLink": t("decidim.accessibility.external_link")
}
validator_messages = {
  "correctErrors": t("forms.correct_errors")
}
%>

<script>
  Decidim.config.set(<%== js_configs.to_json %>);
  Decidim.InputCharacterCounter.configureMessages(<%== character_messages.to_json %>);
  Decidim.ExternalLink.configureMessages(<%== external_link_messages.to_json %>);
  Decidim.FormValidator.configureMessages(<%== validator_messages.to_json %>);
</script>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
decidim-core-0.22.0 app/views/layouts/decidim/_js_configuration.html.erb