mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
384 lines
7.0 KiB
SCSS
384 lines
7.0 KiB
SCSS
.checkout-tab {
|
|
height: 4rem;
|
|
display: flex;
|
|
flex-direction: column;
|
|
justify-content: center;
|
|
|
|
span, span > a {
|
|
font-size: 1.3rem;
|
|
@include headingFont;
|
|
}
|
|
|
|
@media screen and (max-width: 700px) {
|
|
|
|
span, span > a {
|
|
font-size: 1.1rem;
|
|
}
|
|
|
|
span.checkout-tab-number {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
&:not(.selected) {
|
|
background-color: $white;
|
|
border-bottom: 5px solid $min-accessible-grey;
|
|
|
|
span, span > a {
|
|
color: $min-accessible-grey;
|
|
}
|
|
}
|
|
|
|
&.selected {
|
|
background-color: $ofn-brand;
|
|
|
|
span, span > a {
|
|
color: $white;
|
|
}
|
|
}
|
|
|
|
&.success {
|
|
border-bottom: 5px solid $clr-turquoise-bright;
|
|
|
|
span {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
span.checkout-tab-label {
|
|
&:after {
|
|
content: '✓';
|
|
background-color: $clr-turquoise-bright;
|
|
color: $white;
|
|
border-radius: 50%;
|
|
width: 1em;
|
|
height: 1em;
|
|
line-height: 1em;
|
|
display: inline-block;
|
|
font-family: $body-font;
|
|
margin-left: 10px;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
.already-ordered {
|
|
.panel {
|
|
margin-top: 3rem;
|
|
background-color: $grey-250;
|
|
border: 1px solid $tiny-blue;
|
|
color: $grey-700;
|
|
|
|
&.medium-6, &.medium-10 {
|
|
margin-right: auto;
|
|
margin-left: auto;
|
|
}
|
|
}
|
|
}
|
|
|
|
.already-ordered .panel, #distributor_address.panel {
|
|
font-size: 0.875rem;
|
|
padding: 1rem;
|
|
}
|
|
|
|
.checkout-step {
|
|
margin-top: 3rem;
|
|
|
|
.medium-6, .medium-10 {
|
|
margin-right: auto;
|
|
margin-left: auto;
|
|
}
|
|
|
|
.checkout-substep {
|
|
margin-bottom: 1rem;
|
|
margin-top: 5rem;
|
|
|
|
&:first-child {
|
|
margin-top: 3rem;
|
|
}
|
|
}
|
|
|
|
.checkout-title {
|
|
font-size: 1.06rem;
|
|
@include headingFont;
|
|
font-weight: $font-weight-bold;
|
|
color: $darker-grey;
|
|
margin-bottom: 1.5rem;
|
|
}
|
|
|
|
.checkout-input {
|
|
margin-bottom: 1.5rem;
|
|
|
|
.field_with_errors {
|
|
label {
|
|
font-weight: $font-weight-bold;
|
|
color: $red-700;
|
|
}
|
|
input {
|
|
border-color: $red-700;
|
|
}
|
|
}
|
|
|
|
.stripe-card {
|
|
background: white;
|
|
box-sizing: border-box;
|
|
font-weight: 400;
|
|
padding: 0.6rem 0.5rem;
|
|
border: 1px solid #cccccc;
|
|
box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
|
|
border-radius: 0;
|
|
height: 42px;
|
|
width: 100%;
|
|
}
|
|
|
|
label {
|
|
margin-bottom: 0.3rem;
|
|
}
|
|
|
|
input,
|
|
select {
|
|
margin: 0;
|
|
}
|
|
|
|
#distributor_address.panel {
|
|
span {
|
|
@include force-wrap;
|
|
}
|
|
}
|
|
|
|
a {
|
|
color: $teal-400;
|
|
text-decoration: underline;
|
|
}
|
|
|
|
&.checkout-input-radio {
|
|
display: flex;
|
|
align-items: center;
|
|
|
|
input[type=radio] {
|
|
min-width: 12px;
|
|
}
|
|
|
|
label {
|
|
margin-top: 0.3rem;
|
|
& + em {
|
|
margin-left: -0.5rem;
|
|
font-size: 14px; // same as label
|
|
font-weight: bold;
|
|
// Add opening and closing parentheses
|
|
&:before {
|
|
content: "(";
|
|
}
|
|
&:after {
|
|
content: ")";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
.checkout-input span.formError, div.error.card-errors {
|
|
background-color: rgba(193, 18, 43, 0.1);
|
|
color: $red-700;
|
|
font-style: normal;
|
|
margin: 0;
|
|
font-size: 0.8rem;
|
|
display: block;
|
|
padding-left: 5px;
|
|
padding-right: 5px;
|
|
padding-top: 2px;
|
|
padding-bottom: 2px;
|
|
|
|
&.standalone {
|
|
padding: 10px;
|
|
}
|
|
}
|
|
|
|
div.error.card-errors {
|
|
&:empty {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
.paymentmethod-container .paymentmethod-description.panel {
|
|
@include force-wrap;
|
|
}
|
|
|
|
.checkout-step3 {
|
|
padding-left: 15px;
|
|
padding-right: 15px;
|
|
.checkout-submit {
|
|
margin-top: 0;
|
|
margin-bottom: 0;
|
|
padding-top: 2rem;
|
|
|
|
.button {
|
|
margin-bottom: 1rem;
|
|
}
|
|
}
|
|
|
|
&.sticked {
|
|
background-color: $white;
|
|
box-shadow: 0 -6px 12px -6px rgba(0, 0, 0, 0.33);
|
|
border-left: 1px solid $light-grey;
|
|
border-right: 1px solid $light-grey;
|
|
border-top: 1px solid $light-grey;
|
|
}
|
|
|
|
@media screen and (max-width: 700px) {
|
|
&.sticked {
|
|
width: auto;
|
|
margin-left: -15px;
|
|
margin-right: -15px;
|
|
box-shadow: 0 0px 10px 0px rgba(0, 0, 0, 0.33);
|
|
|
|
.checkout-submit {
|
|
width: 100%;
|
|
padding-left: 15px;
|
|
padding-right: 15px;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
.checkout-submit {
|
|
margin-top: 5rem;
|
|
margin-bottom: 5rem;
|
|
|
|
.button {
|
|
width: 100%;
|
|
margin-bottom: 2rem;
|
|
border-radius: 0.5em;
|
|
|
|
&.primary {
|
|
background-color: $orange-500;
|
|
}
|
|
|
|
&.cancel {
|
|
background-color: $white;
|
|
border: 1px solid $orange-500;
|
|
color: $orange-500;
|
|
|
|
}
|
|
}
|
|
|
|
&.checkout-submit-inline {
|
|
display: flex;
|
|
align-items: baseline;
|
|
justify-content: space-between;
|
|
|
|
@media screen and (max-width: 700px) {
|
|
flex-direction: column;
|
|
}
|
|
|
|
.checkout-submit-or {
|
|
margin-left: 20px;
|
|
margin-right: 20px;
|
|
text-transform: uppercase;
|
|
color: $min-accessible-grey;
|
|
|
|
@media screen and (max-width: 700px) {
|
|
display: none;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
.checkout-guest-title {
|
|
font-size: 1.5rem;
|
|
@include headingFont;
|
|
text-align: center;
|
|
color: $min-accessible-grey;
|
|
}
|
|
}
|
|
|
|
.summary {
|
|
margin-bottom: 2px;
|
|
font-size: 0.875rem;
|
|
|
|
.summary-label {
|
|
font-weight: bold;
|
|
}
|
|
|
|
.summary-description {
|
|
@include force-wrap;
|
|
color: $min-accessible-grey;
|
|
}
|
|
|
|
.summary-edit {
|
|
color: $teal-400;
|
|
text-decoration: underline;
|
|
display: block;
|
|
margin-top: 5px;
|
|
&:after {
|
|
background-image: url("../images/edit-with-pen.svg");
|
|
content: " ";
|
|
display: inline-block;
|
|
width: 1em;
|
|
height: 1em;
|
|
margin-left: 5px;
|
|
line-height: 1em;
|
|
position: relative;
|
|
top: 2px;
|
|
}
|
|
}
|
|
}
|
|
|
|
#line-items {
|
|
display: block;
|
|
overflow-x: auto;
|
|
}
|
|
|
|
.two-columns-inputs {
|
|
display: flex;
|
|
gap: 1rem;
|
|
justify-content: space-between;
|
|
|
|
> .checkout-input {
|
|
flex: 1;
|
|
}
|
|
|
|
&:last-child > .checkout-input {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
@media screen and (max-width: 700px) {
|
|
flex-direction: column;
|
|
gap: 0;
|
|
&:last-child > .checkout-input {
|
|
margin-bottom: 1.5rem;
|
|
}
|
|
}
|
|
}
|
|
|
|
// Shows label as a placeholder, inside the input and when the input is focused shows the label above the input
|
|
.checkout-input.with-floating-label {
|
|
position: relative;
|
|
|
|
label {
|
|
display: none; // Display none by default, and shown by floating_label_controller
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
font-size: 0.875rem;
|
|
padding: 8px;
|
|
padding-left: 9px;
|
|
color: $min-accessible-grey;
|
|
pointer-events: none;
|
|
transform: translateY(0);
|
|
transform-origin: top left;
|
|
&.with-transition {
|
|
transition: all 0.2s ease-in-out;
|
|
}
|
|
}
|
|
&.active {
|
|
label {
|
|
transform: translateY(-9px) translateX(10px) scale(0.9);
|
|
background-color: white;
|
|
padding-left: 3px;
|
|
padding-right: 3px;
|
|
padding-top: 0;
|
|
padding-bottom: 0;
|
|
}
|
|
}
|
|
}
|