yamlform.progress.bar.css in YAML Form 8
Wizard progress bar styles.
File
css/yamlform.progress.bar.cssView source
- /**
- * @file
- * Wizard progress bar styles.
- */
-
- /**
- * Progress bar.
- *
- * @see https://coderwall.com/p/-7trcg/simple-css-only-wizard-progress-tracker
- */
- .yamlform-progress-bar {
- margin: 0;
- padding: 0;
- overflow: hidden;
- font-size: smaller;
- }
-
- li.yamlform-progress-bar__page {
- list-style-type: none;
- display: inline-block;
- position: relative;
- margin: 0;
- padding: 0;
- line-height: 30px;
- height: 30px;
- background-color: #f0f0f0;
- }
-
- .yamlform-progress-bar[data-steps="2"] li {
- width: 50%;
- }
- .yamlform-progress-bar[data-steps="3"] li {
- width: 33%;
- }
- .yamlform-progress-bar[data-steps="4"] li {
- width: 25%;
- }
- .yamlform-progress-bar[data-steps="5"] li {
- width: 20%;
- }
- .yamlform-progress-bar[data-steps="6"] li {
- width: 16.6%;
- }
- .yamlform-progress-bar[data-steps="7"] li {
- width: 14.28%;
- }
- .yamlform-progress-bar[data-steps="8"] li {
- width: 12.5%;
- }
- .yamlform-progress-bar[data-steps="9"] li {
- width: 11.11%;
- }
- .yamlform-progress-bar[data-steps="10"] li {
- width: 10%;
- }
-
- li.yamlform-progress-bar__page > b {
- display: block;
- padding: 0 0 0 30px;
- font-weight: normal;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- }
-
- li.yamlform-progress-bar__page--done > b {
- background-color: #dbdbdb;
- }
-
- li.yamlform-progress-bar__page--current > b {
- font-weight: bold;
- }
-
- li.yamlform-progress-bar__page > b:after,
- li.yamlform-progress-bar__page > b:before {
- content: "";
- display: block;
- width: 0;
- height: 0;
- position: absolute;
- top: 0;
- left: 0;
- border: solid transparent;
- border-left-color: #ededed;
- border-width: 15px;
- }
-
- li.yamlform-progress-bar__page > b:after {
- top: -5px;
- z-index: 1;
- border-left-color: white;
- border-width: 20px;
- }
-
- li.yamlform-progress-bar__page > b:before {
- z-index: 2;
- }
-
- li.yamlform-progress-bar__page--done + li > b:before {
- border-left-color: #dbdbdb;
- }
-
- li.yamlform-progress-bar__page:first-child > b:after,
- li:first-child > b:before {
- display: none;
- }
-
- li.yamlform-progress-bar__page:first-child span,
- li.yamlform-progress-bar__page:last-child span {
- display: block;
- height: 0;
- width: 0;
- position: absolute;
- top: 0;
- left: 0;
- border: solid transparent;
- border-left-color: white;
- border-width: 15px;
- }
-
- li.yamlform-progress-bar__page:last-child span {
- left: auto;
- right: -15px;
- border-left-color: transparent;
- border-top-color: white;
- border-bottom-color: white;
- }