// @page Pattern Library/Components // @name Progress navigation // // @description // The progress navigation should be used for any funnel journeys on the website. Once a section has been completed the user should be able to get back to that step. // The mobile view of the navigation just has the dotted numbers. // // @markup //
// //
// $progress-bg-color: $c-white; $progress-current-color: $c-white; $progress-complete-color: $c-uswitch-navy; $progress-next-color: $c-grey; .us-progress { position: relative; z-index: 4; background-color: $progress-bg-color; } .us-progress__nav { @extend %reset-box-model; list-style: none; counter-reset: number-counter; } .us-progress__item { @extend %reset-box-model; position: relative; float: left; line-height: 1.5em; counter-increment: number-counter; @include respond-to(tablet, true) { margin-right: $gutter-width; } } .us-progress__link { position: relative; display: block; padding-top: .5em; padding-bottom: .5em; @include respond-to(tablet, true) { padding-top: 1em; padding-bottom: 1em; } &:before { position: relative; display: inline-block; width: 1.5em; height: 1.5em; margin-right: $gutter-width/3; font-weight: 500; color: $c-white; text-align: center; border-radius: 50%; content: counter(number-counter); transition: background-color .3s; border-width: 3px; border-style: solid; } } .us-progress__link--next { color: $c-uswitch-navy; &:before { border-color: $progress-next-color; background-color: $progress-next-color; } } .us-progress__link--current { color: $c-uswitch-navy; &:before { color: $c-uswitch-navy; background-color: $progress-current-color; border-color: $c-uswitch-navy; } } .us-progress__link--complete { @include link-colors($progress-complete-color, #fff, $progress-complete-color, $progress-complete-color, #fff); text-decoration: none; &:hover { text-decoration: underline; text-decoration-color: $c-uswitch-navy; } &:before { background-color: $progress-complete-color; border-color: $c-uswitch-navy; } &:hover span, &:focus span { color: $c-uswitch-navy; } }