Sha256: d1f1ac9082af60f338566cebcc7ef93a554dcc0f9c18b1acdde5565595942fc1

Contents?: true

Size: 1.6 KB

Versions: 4

Compression:

Stored size: 1.6 KB

Contents

@import "../../settings/all";
@import "../../tools/all";
@import "../../helpers/all";

@import "../error-message/error-message";
@import "../hint/hint";
@import "../label/label";

@include govuk-exports("govuk/component/input") {
  .govuk-input {
    @include govuk-font($size: 19);
    @include govuk-focusable;

    -webkit-box-sizing: border-box;

            box-sizing: border-box;
    width: 100%;
    height: 40px;
    margin-top: 0;

    padding: govuk-spacing(1);
    // setting any background-color makes text invisible when changing colours to dark backgrounds in Firefox (https://bugzilla.mozilla.org/show_bug.cgi?id=1335476)
    // as background-color and color need to always be set together, color should not be set either
    border: $govuk-border-width-form-element solid $govuk-input-border-colour;
    border-radius: 0;

    // Disable inner shadow and remove rounded corners
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
  }

  .govuk-input::-webkit-outer-spin-button,
  .govuk-input::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
  }

  .govuk-input[type="number"] {
    -moz-appearance: textfield;
  }

  .govuk-input--error {
    border: $govuk-border-width-form-element-error solid $govuk-error-colour;
  }

  // The ex measurements are based on the number of W's that can fit inside the input
  // Extra space is left on the right hand side to allow for the Safari prefill icon

  .govuk-input--width-30 {
    max-width: 60ex;
  }

  .govuk-input--width-20 {
    max-width: 41ex;
  }

  .govuk-input--width-10 {
    max-width: 23ex;
  }

}

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
govuk_publishing_components-9.5.1 node_modules/govuk-frontend/components/input/_input.scss
govuk_publishing_components-9.5.0 node_modules/govuk-frontend/components/input/_input.scss
govuk_publishing_components-9.4.0 node_modules/govuk-frontend/components/input/_input.scss
govuk_fe_assets-0.1.0.pre.alpha node_modules/govuk-frontend/components/input/_input.scss