UNPKG

govuk-frontend

Version:

GOV.UK Frontend contains the code you need to start building a user interface for government platforms and services.

2 lines (1 loc) 1.92 kB
{"version":3,"sources":["../../../../src/govuk/components/character-count/_index.scss"],"names":[],"mappings":"AAAA,oBAAoB;;AAEpB,gCAAgC;AAChC,uBAAuB;AACvB,wBAAwB;AACxB,2BAA2B;;AAE3B;EACE;IACE,6CAA6C;;IAE7C;;MAEE,+BAA+B;IACjC;;IAEA,0EAA0E;IAC1E,yEAAyE;IACzE,wDAAwD;IACxD;MACE,4CAA4C;MAC5C,uFAAuF;IACzF;EACF;;EAEA;IACE,mCAAmC;IACnC,aAAa;IACb,gBAAgB;;IAEhB;MACE,mEAAmE;MACnE,cAAc;MACd,uEAAuE;MACvE,yDAAyD;MACzD,wEAAwE;MACxE,gBAAgB;IAClB;EACF;;EAEA;IACE,kBAAkB;EACpB;AACF","file":"_index.scss","sourcesContent":["@import \"../../base\";\n\n@import \"../error-message/index\";\n@import \"../hint/index\";\n@import \"../label/index\";\n@import \"../textarea/index\";\n\n@include govuk-exports(\"govuk/component/character-count\") {\n .govuk-character-count {\n @include govuk-responsive-margin(6, \"bottom\");\n\n .govuk-form-group,\n .govuk-textarea {\n margin-bottom: govuk-spacing(1);\n }\n\n // If the textarea enters the error state whilst the user is focused on it,\n // show the error state. This presents feedback to the user that the value\n // has become invalid without needing to see the counter.\n .govuk-textarea--error:focus {\n border-color: govuk-functional-colour(error);\n box-shadow: inset 0 0 0 $govuk-border-width-form-element govuk-functional-colour(error);\n }\n }\n\n .govuk-character-count__message {\n @include govuk-font-tabular-numbers;\n margin-top: 0;\n margin-bottom: 0;\n\n &::after {\n // Zero-width space that will reserve vertical space when no hint is\n // provided as:\n // - setting a min-height is not possible without a magic number because\n // the line-height is set by the `govuk-font` call above\n // - using `:empty` is not possible as the hint macro outputs line breaks\n content: \"\\200B\";\n }\n }\n\n .govuk-character-count__message--disabled {\n visibility: hidden;\n }\n}\n"]}