2024-09-13 19:36:08 +02:00
|
|
|
// Variables
|
|
|
|
$border-color: hsla(0, 0%, 7%, 0.11);
|
|
|
|
$transition-duration: 0.3s;
|
|
|
|
$fast-transition-duration: 0.5s;
|
2024-09-05 21:17:36 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// Mixins
|
|
|
|
@mixin flex-center {
|
2024-09-05 21:17:36 +02:00
|
|
|
display: flex;
|
|
|
|
justify-content: center;
|
2024-09-06 13:06:37 +02:00
|
|
|
align-items: center;
|
2024-09-05 21:17:36 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
@mixin flex-space-between {
|
2024-09-06 13:06:37 +02:00
|
|
|
display: flex;
|
2024-09-13 19:36:08 +02:00
|
|
|
justify-content: space-between;
|
2024-09-06 13:06:37 +02:00
|
|
|
align-items: center;
|
2024-09-05 21:17:36 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 1. AXO Block Radio Label
|
2024-10-16 12:51:26 +02:00
|
|
|
.wc-block-checkout__payment-method label[for="radio-control-wc-payment-method-options-ppcp-axo-gateway"] {
|
|
|
|
padding-right: .875em;
|
|
|
|
}
|
|
|
|
|
|
|
|
#radio-control-wc-payment-method-options-ppcp-axo-gateway__label {
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
2024-09-06 13:06:37 +02:00
|
|
|
width: 100%;
|
2024-09-13 19:36:08 +02:00
|
|
|
padding-right: 1em;
|
2024-10-16 12:51:26 +02:00
|
|
|
|
|
|
|
.wc-block-components-payment-method-icons {
|
|
|
|
margin: 0;
|
|
|
|
}
|
2024-09-05 21:17:36 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 2. AXO Block Card
|
|
|
|
.wc-block-checkout-axo-block-card {
|
|
|
|
@include flex-center;
|
2024-09-05 21:17:36 +02:00
|
|
|
width: 100%;
|
2024-09-17 14:22:36 +02:00
|
|
|
margin-bottom: 2em;
|
2024-09-05 21:17:36 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
&__inner {
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
align-items: center;
|
|
|
|
max-width: 300px;
|
|
|
|
width: 100%;
|
|
|
|
}
|
2024-09-05 21:17:36 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
&__content {
|
|
|
|
box-sizing: border-box;
|
|
|
|
aspect-ratio: 1.586;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
justify-content: space-between;
|
|
|
|
border: 1px solid $border-color;
|
|
|
|
font-size: 0.875em;
|
|
|
|
font-family: monospace;
|
|
|
|
padding: 1em;
|
|
|
|
margin: 1em 0;
|
|
|
|
border-radius: 4px;
|
|
|
|
width: 100%;
|
|
|
|
}
|
|
|
|
|
|
|
|
&__meta {
|
|
|
|
@include flex-space-between;
|
|
|
|
width: 100%;
|
2024-09-06 13:06:37 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
&-digits {
|
|
|
|
letter-spacing: 2px;
|
|
|
|
}
|
2024-09-06 13:06:37 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
&:last-child {
|
|
|
|
align-self: flex-end;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&__watermark {
|
|
|
|
align-self: flex-end;
|
2024-09-06 13:06:37 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
&__edit {
|
2024-10-16 12:51:26 +02:00
|
|
|
flex-grow: 1;
|
|
|
|
margin-left: auto;
|
|
|
|
text-align: right;
|
2024-09-13 19:36:08 +02:00
|
|
|
border: 0;
|
|
|
|
font-family: inherit;
|
|
|
|
font-size: 0.875em;
|
|
|
|
font-weight: normal;
|
2024-10-16 12:51:26 +02:00
|
|
|
color: inherit;
|
|
|
|
background-color: transparent;
|
|
|
|
cursor: pointer;
|
2024-09-13 19:36:08 +02:00
|
|
|
|
|
|
|
&:hover {
|
|
|
|
text-decoration: underline;
|
|
|
|
}
|
|
|
|
}
|
2024-09-05 21:17:36 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
.wc-block-axo-block-card__meta-icon {
|
|
|
|
max-height: 25px;
|
|
|
|
}
|
2024-09-10 18:46:27 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 3. Express Payment Block
|
2024-09-10 18:46:27 +02:00
|
|
|
.wp-block-woocommerce-checkout-express-payment-block {
|
2024-09-13 19:36:08 +02:00
|
|
|
transition: opacity $transition-duration ease-in,
|
|
|
|
scale $transition-duration ease-in,
|
|
|
|
display $transition-duration ease-in;
|
2024-09-10 18:46:27 +02:00
|
|
|
transition-behavior: allow-discrete;
|
|
|
|
|
|
|
|
@starting-style {
|
|
|
|
opacity: 0;
|
|
|
|
scale: 1.1;
|
|
|
|
}
|
|
|
|
|
|
|
|
&.wc-block-axo-is-authenticated {
|
|
|
|
opacity: 0;
|
2024-09-13 19:36:08 +02:00
|
|
|
scale: 0.9;
|
2024-09-10 18:46:27 +02:00
|
|
|
display: none !important;
|
2024-09-13 19:36:08 +02:00
|
|
|
transition-duration: $fast-transition-duration;
|
2024-09-10 18:46:27 +02:00
|
|
|
transition-timing-function: var(--ease-out-5);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 4. AXO Loaded State
|
|
|
|
.wc-block-axo-is-loaded {
|
|
|
|
// 4.1 Text Input
|
|
|
|
.wc-block-components-text-input {
|
|
|
|
display: flex;
|
|
|
|
margin-bottom: 0.5em;
|
|
|
|
}
|
2024-09-10 18:46:27 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 4.2 Hidden Fields
|
|
|
|
&:not(.wc-block-axo-email-lookup-completed) {
|
|
|
|
#shipping-fields,
|
|
|
|
#billing-fields,
|
|
|
|
#shipping-option,
|
2024-09-17 14:22:36 +02:00
|
|
|
#order-notes,
|
|
|
|
.wp-block-woocommerce-checkout-terms-block,
|
|
|
|
.wp-block-woocommerce-checkout-actions-block {
|
2024-09-13 19:36:08 +02:00
|
|
|
display: none;
|
|
|
|
}
|
2024-09-13 19:24:23 +02:00
|
|
|
}
|
2024-09-13 17:27:39 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 4.3 Authenticated State
|
2024-09-13 17:27:39 +02:00
|
|
|
&.wc-block-axo-is-authenticated .wc-block-components-text-input {
|
|
|
|
gap: 14px 0;
|
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 4.4 Contact Information Block
|
2024-09-13 17:27:39 +02:00
|
|
|
.wp-block-woocommerce-checkout-contact-information-block .wc-block-components-text-input {
|
2024-09-10 18:46:27 +02:00
|
|
|
display: grid;
|
|
|
|
grid-template-areas:
|
2024-09-17 14:13:29 +02:00
|
|
|
"input"
|
|
|
|
"button"
|
|
|
|
"watermark"
|
|
|
|
"error";
|
|
|
|
grid-template-columns: 1fr;
|
|
|
|
gap: 6px;
|
2024-09-10 18:46:27 +02:00
|
|
|
align-items: start;
|
2024-09-13 19:36:08 +02:00
|
|
|
|
|
|
|
input[type="email"] {
|
|
|
|
grid-area: input;
|
|
|
|
width: 100%;
|
|
|
|
}
|
2024-09-10 18:46:27 +02:00
|
|
|
}
|
|
|
|
|
2024-09-11 22:58:13 +02:00
|
|
|
#email {
|
2024-09-17 14:13:29 +02:00
|
|
|
align-self: stretch;
|
2024-09-11 22:58:13 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 4.5 Email Submit Button
|
2024-09-10 18:46:27 +02:00
|
|
|
.wc-block-axo-email-submit-button-container {
|
|
|
|
grid-area: button;
|
2024-09-17 14:13:29 +02:00
|
|
|
align-self: stretch;
|
2024-09-13 19:36:08 +02:00
|
|
|
|
|
|
|
.wc-block-components-button {
|
|
|
|
white-space: nowrap;
|
2024-09-17 14:13:29 +02:00
|
|
|
width: 100%;
|
2024-09-13 19:36:08 +02:00
|
|
|
}
|
2024-09-10 18:46:27 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 4.6 Watermark Container
|
2024-09-10 18:46:27 +02:00
|
|
|
.wc-block-checkout-axo-block-watermark-container {
|
|
|
|
grid-area: watermark;
|
2024-09-18 23:24:46 +02:00
|
|
|
justify-self: end;
|
|
|
|
grid-column: 1;
|
|
|
|
margin-top: 0;
|
2024-09-10 18:46:27 +02:00
|
|
|
}
|
|
|
|
|
2024-09-18 23:27:36 +02:00
|
|
|
// 4.7 Validation Error
|
2024-09-16 16:25:16 +02:00
|
|
|
.wc-block-components-address-form__email .wc-block-components-validation-error {
|
2024-09-10 18:46:27 +02:00
|
|
|
grid-area: error;
|
|
|
|
width: 100%;
|
|
|
|
margin-top: 4px;
|
2024-09-18 23:24:46 +02:00
|
|
|
grid-row: 3;
|
|
|
|
|
|
|
|
@media (min-width: 783px) {
|
|
|
|
grid-row: 2;
|
|
|
|
}
|
2024-09-10 18:46:27 +02:00
|
|
|
}
|
2024-09-17 14:13:29 +02:00
|
|
|
|
|
|
|
@media (min-width: 783px) {
|
|
|
|
.wp-block-woocommerce-checkout-contact-information-block .wc-block-components-text-input {
|
|
|
|
grid-template-areas:
|
|
|
|
"input button"
|
|
|
|
"watermark watermark"
|
|
|
|
"error error";
|
|
|
|
grid-template-columns: 1fr auto;
|
|
|
|
gap: 6px 8px;
|
|
|
|
}
|
|
|
|
|
|
|
|
#email {
|
|
|
|
align-self: center;
|
|
|
|
}
|
|
|
|
|
|
|
|
.wc-block-axo-email-submit-button-container {
|
|
|
|
align-self: center;
|
|
|
|
|
|
|
|
.wc-block-components-button {
|
|
|
|
width: auto;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2024-09-17 22:44:57 +02:00
|
|
|
|
|
|
|
// 4.8 Counter fix
|
|
|
|
.wc-block-checkout__form {
|
|
|
|
counter-reset: visible-step;
|
|
|
|
|
|
|
|
.wc-block-components-checkout-step--with-step-number {
|
|
|
|
counter-increment: visible-step;
|
|
|
|
|
|
|
|
.wc-block-components-checkout-step__title:before {
|
|
|
|
content: counter(visible-step) ". ";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2024-09-11 00:39:09 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 5. Shipping/Card Change Link
|
2024-09-11 00:39:09 +02:00
|
|
|
a.wc-block-axo-change-link {
|
2024-09-13 19:36:08 +02:00
|
|
|
color: var(--wp--preset--color--secondary);
|
|
|
|
text-decoration: underline;
|
2024-09-11 00:39:09 +02:00
|
|
|
|
|
|
|
&:hover {
|
|
|
|
text-decoration: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:focus {
|
|
|
|
text-decoration: underline dashed;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:active {
|
|
|
|
color: var(--wp--preset--color--secondary);
|
|
|
|
text-decoration: none;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 6. Watermark Container
|
2024-09-11 00:39:09 +02:00
|
|
|
.wc-block-checkout-axo-block-watermark-container {
|
|
|
|
height: 25px;
|
2024-09-13 19:36:08 +02:00
|
|
|
margin-top: 5px;
|
|
|
|
margin-left: 5px;
|
2024-09-11 00:39:09 +02:00
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 7. Checkout Fields Block (AXO Not Loaded)
|
|
|
|
.wp-block-woocommerce-checkout-fields-block:not(.wc-block-axo-is-loaded) {
|
|
|
|
.wc-block-checkout-axo-block-watermark-container {
|
|
|
|
display: flex;
|
2024-10-10 20:40:03 +02:00
|
|
|
justify-content: right;
|
|
|
|
margin-right: 10px;
|
2024-09-13 19:36:08 +02:00
|
|
|
align-items: center;
|
2024-09-11 00:39:09 +02:00
|
|
|
position: relative;
|
2024-09-13 19:36:08 +02:00
|
|
|
|
|
|
|
.wc-block-components-spinner {
|
|
|
|
box-sizing: content-box;
|
|
|
|
color: inherit;
|
|
|
|
font-size: 1em;
|
|
|
|
height: auto;
|
|
|
|
width: auto;
|
|
|
|
position: relative;
|
|
|
|
margin-top: 12px;
|
|
|
|
}
|
2024-09-11 00:39:09 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 8. AXO Loaded Contact Information Block
|
2024-09-13 17:27:39 +02:00
|
|
|
.wc-block-axo-is-loaded .wp-block-woocommerce-checkout-contact-information-block {
|
2024-09-11 00:39:09 +02:00
|
|
|
.wc-block-checkout-axo-block-watermark-container .wc-block-components-spinner {
|
|
|
|
display: none;
|
|
|
|
visibility: hidden;
|
|
|
|
opacity: 0;
|
|
|
|
}
|
|
|
|
}
|
2024-09-10 18:46:27 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 9. Transitions
|
2024-09-11 00:39:09 +02:00
|
|
|
.wc-block-axo-email-submit-button-container,
|
|
|
|
.wc-block-checkout-axo-block-watermark-container #fastlane-watermark-email,
|
2024-09-13 19:36:08 +02:00
|
|
|
a.wc-block-axo-change-link {
|
2024-09-11 00:39:09 +02:00
|
|
|
transition: opacity 0.5s ease-in-out;
|
|
|
|
|
|
|
|
@starting-style {
|
|
|
|
opacity: 0;
|
|
|
|
scale: 1.1;
|
2024-09-10 18:46:27 +02:00
|
|
|
}
|
|
|
|
}
|
2024-09-11 00:39:09 +02:00
|
|
|
|
2024-09-13 19:36:08 +02:00
|
|
|
// 10. Shipping Fields
|
2024-09-11 22:58:13 +02:00
|
|
|
#shipping-fields .wc-block-components-checkout-step__heading {
|
|
|
|
display: flex;
|
|
|
|
}
|
2024-10-01 15:48:27 +02:00
|
|
|
|
|
|
|
// 11. Fastlane modal info message fix
|
|
|
|
.wc-block-components-text-input {
|
|
|
|
.wc-block-components-form &,
|
|
|
|
& {
|
|
|
|
paypal-watermark {
|
|
|
|
white-space: wrap;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|