Skip to content
forked from hmrc/play-ui

Core for HMRC's UI, incl. formatters, validators, mappers and helper templates

License

Notifications You must be signed in to change notification settings

Jagordon/play-ui

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

play-ui

Join the chat at https://gitter.im/hmrc/play-ui Build Status Download

Micro-library containing core for HMRC's Play UI:

Formatters

  • Dates provides various human-readable date formats
  • Money formats pounds and pence
  • Strings changes the case of phrases and hyphenates

Form Mappers & Validators

  • DateTuple maps year, month, day fields to a LocalDate
  • StopOnFirstFail applies constraints in order and fails fast
  • Validators contains multiple small validation functions such as addressTuple, positiveInteger & nonEmptySmallText

Helper Templates

Has many standard snippets for form fields, such as: address, dateFields, dropdown, fieldGroup. Each helper correctly adds labels, error messages and CSS classes.

Layout Templates

Contains templates for components used across frontend applications such as: header, footer, sidebar, betaBanner.

Adding to your service

Include the following dependency in your SBT build

resolvers += Resolver.bintrayRepo("hmrc", "releases")

libraryDependencies += "uk.gov.hmrc" %% "play-ui" % "x.x.x"

License

This code is open source software licensed under the Apache 2.0 License.

About

Core for HMRC's UI, incl. formatters, validators, mappers and helper templates

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • HTML 52.9%
  • Scala 47.1%