ltsecurityinc安防产品在线商城代码

This commit is contained in:
2026-09-14 17:47:10 +08:00
parent 57d8444c15
commit 6a3c9c5bd8
14539 changed files with 1775310 additions and 0 deletions
@@ -0,0 +1,25 @@
<?xml version="1.0"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="page.main.title" remove="true" />
<referenceContainer name="content">
<referenceContainer name="checkout.cart.container">
<container name="cart.page.title.wrapper" htmlTag="div" htmlClass="cart page-title-wrapper" before="-">
<block class="Magento\Checkout\Block\Cart" name="ox.checkout.cart.page.title" as="ox.cart.page.title" template="Magento_Checkout::cart/title.phtml"/>
<block class="Magento\Checkout\Block\Onepage\Link" name="checkout.cart.methods.onepage.intitle" template="Magento_Checkout::onepage/link.phtml" />
</container>
</referenceContainer>
</referenceContainer>
<referenceBlock name="checkout.cart.crosssell">
<action method="setTemplate">
<argument name="template" xsi:type="helper" helper="Olegnax\Athlete2\Helper\UpdaterTemplate::setCrossSellProductsLayout"/>
</action>
</referenceBlock>
</body>
</page>
@@ -0,0 +1,24 @@
<?xml version="1.0"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="checkout" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceContainer name="page.wrapper">
<block name="athlete2_header_checkout" class="Olegnax\Athlete2\Block\Template" template="Magento_Checkout::checkout/header.phtml" before="main.content">
</block>
</referenceContainer>
<move element="logo" destination="athlete2_header_checkout"/>
<referenceBlock name="page.main.title" remove="true"/>
<referenceBlock name="header_banner" remove="true" />
<referenceBlock name="above_footer_block" remove="true" />
<referenceBlock name="above_footer_banner" remove="true" />
<referenceContainer name="above_footer" remove="1" />
<referenceBlock name="athlete2_header" remove="true"/>
<referenceBlock name="athlete2_navigation" remove="true"/>
</body>
</page>
@@ -0,0 +1,39 @@
<?xml version="1.0"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<head>
<title>Success Page</title>
</head>
<body>
<referenceBlock name="page.main.title">
<container name="success-icon-wrapper" htmlTag="div" before="-" htmlClass="success-icon-wrapper">
<container name="success-icon" htmlTag="div" htmlClass="success-icon">
<block class="Magento\Framework\View\Element\Text">
<arguments>
<argument name="text" xsi:type="string"><![CDATA[<!-- success-icon -->]]></argument>
</arguments>
</block>
</container>
</container>
<block class="Magento\Checkout\Block\Onepage\Success" name="checkout.success.print.button" template="Magento_Checkout::button.phtml"/>
<action method="setPageTitle">
<argument translate="true" name="title" xsi:type="string">Thank you for your purchase!</argument>
</action>
</referenceBlock>
<move element="page.main.title" destination="content" before="-"/>
<referenceContainer name="content">
<container name="content-wrapper" htmlTag="div" htmlClass="checkout-success-wrapper">
<block class="Magento\Checkout\Block\Onepage\Success" name="checkout.success" template="Magento_Checkout::success.phtml" cacheable="false">
<container name="order.success.additional.info" label="Order Success Additional Info"/>
</block>
<block class="Magento\Checkout\Block\Registration" name="checkout.registration" template="Magento_Checkout::registration.phtml" cacheable="false"/>
</container>
</referenceContainer>
<move element="checkout.success.print.button" destination="content-wrapper" after="-"/>
</body>
</page>
@@ -0,0 +1,83 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
// phpcs:disable Magento2.Templates.ThisInTemplate
/** @var $block \Magento\Checkout\Block\Cart\Grid */
?>
<?php $mergedCells = ($this->helper(Magento\Tax\Helper\Data::class)->displayCartBothPrices() ? 2 : 1); ?>
<?= $block->getChildHtml('form_before') ?>
<form action="<?= $block->escapeUrl($block->getUrl('checkout/cart/updatePost')) ?>"
method="post"
id="form-validate"
data-mage-init='{"Magento_Checkout/js/action/update-shopping-cart":
{"validationURL" : "<?= $block->escapeUrl($block->getUrl('checkout/cart/updateItemQty')) ?>",
"updateCartActionContainer": "#update_cart_action_container"}
}'
class="form form-cart">
<?= $block->getBlockHtml('formkey') ?>
<div class="cart table-wrapper<?= $mergedCells == 2 ? ' detailed' : '' ?>">
<?php if ($block->getPagerHtml()): ?>
<div class="cart-products-toolbar cart-products-toolbar-top toolbar"
data-attribute="cart-products-toolbar-top"><?= $block->getPagerHtml() ?>
</div>
<?php endif ?>
<table id="shopping-cart-table"
class="cart items data table"
data-mage-init='{"shoppingCart":{"emptyCartButton": "#empty_cart_button",
"updateCartActionContainer": "#update_cart_action_container"}}'>
<caption class="table-caption"><?= $block->escapeHtml(__('Shopping Cart Items')) ?></caption>
<thead>
<tr>
<th class="col item" scope="col"><span><?= $block->escapeHtml(__('Item')) ?></span></th>
<th class="col price" scope="col"><span><?= $block->escapeHtml(__('Price')) ?></span></th>
<th class="col qty" scope="col"><span><?= $block->escapeHtml(__('Qty')) ?></span></th>
<th class="col subtotal" scope="col"><span><?= $block->escapeHtml(__('Subtotal')) ?></span></th>
<th class="col actions" scope="col"><span><?= $block->escapeHtml(__('Actions')) ?></span></th>
</tr>
</thead>
<?php foreach ($block->getItems() as $_item): ?>
<?= $block->getItemHtml($_item) ?>
<?php endforeach ?>
</table>
<?php if ($block->getPagerHtml()): ?>
<div class="cart-products-toolbar cart-products-toolbar-bottom toolbar"
data-attribute="cart-products-toolbar-bottom"><?= $block->getPagerHtml() ?>
</div>
<?php endif ?>
</div>
<div class="cart main actions">
<?php if ($block->getContinueShoppingUrl()) :?>
<a class="action continue"
href="<?= $block->escapeUrl($block->getContinueShoppingUrl()) ?>"
title="<?= $block->escapeHtmlAttr(__('Continue Shopping')) ?>">
<span><?= $block->escapeHtml(__('Continue Shopping')) ?></span>
</a>
<?php endif; ?>
<?php if ($block->getViewModel()->isClearShoppingCartEnabled()): ?>
<button type="button"
name="update_cart_action"
data-cart-empty=""
value="empty_cart"
title="<?= $block->escapeHtmlAttr(__('Clear Shopping Cart')) ?>"
class="action clear" id="empty_cart_button">
<span><?= $block->escapeHtml(__('Clear Shopping Cart')) ?></span>
</button>
<?php endif ?>
<button type="submit"
name="update_cart_action"
data-cart-item-update=""
value="update_qty"
title="<?= $block->escapeHtmlAttr(__('Update Shopping Cart')) ?>"
class="action update">
<span><?= $block->escapeHtml(__('Update Shopping Cart')) ?></span>
</button>
<input type="hidden" value="" id="update_cart_action_container" data-cart-item-update=""/>
</div>
</form>
<?= $block->getChildHtml('checkout.cart.order.actions') ?>
<?= $block->getChildHtml('shopping.cart.table.after') ?>
@@ -0,0 +1,151 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
// phpcs:disable Magento2.Templates.ThisInTemplate
// phpcs:disable Generic.Files.LineLength
/** @var $block Renderer */
use Magento\Checkout\Block\Cart\Item\Renderer;
use Magento\Msrp\Helper\Data;
$_item = $block->getItem();
$product = $_item->getProduct();
$isVisibleProduct = $product->isVisibleInSiteVisibility();
/** @var Data $helper */
$helper = $this->helper(Magento\Msrp\Helper\Data::class);
$canApplyMsrp = $helper->isShowBeforeOrderConfirm($product) && $helper->isMinimalPriceLessMsrp($product);
?>
<tbody class="cart item">
<tr class="item-info">
<td data-th="<?= $block->escapeHtml(__('Item')) ?>" class="col item">
<?php if ($block->hasProductUrl()):?>
<a href="<?= $block->escapeUrl($block->getProductUrl()) ?>"
title="<?= $block->escapeHtml($block->getProductName()) ?>"
tabindex="-1"
class="product-item-photo">
<?php else:?>
<span class="product-item-photo">
<?php endif;?>
<?= $block->getImage($block->getProductForThumbnail(), 'cart_page_product_thumbnail')->toHtml() ?>
<?php if ($block->hasProductUrl()):?>
</a>
<?php else: ?>
</span>
<?php endif; ?>
<div class="product-item-details">
<strong class="product-item-name">
<?php if ($block->hasProductUrl()):?>
<a href="<?= $block->escapeUrl($block->getProductUrl()) ?>"><?= $block->escapeHtml($block->getProductName()) ?></a>
<?php else: ?>
<?= $block->escapeHtml($block->getProductName()) ?>
<?php endif; ?>
<br/>
<?= $block->escapeHtml($block->getItem()->getSku());?>
</strong>
<?php if ($_options = $block->getOptionList()):?>
<dl class="item-options">
<?php foreach ($_options as $_option) : ?>
<?php $_formatedOptionValue = $block->getFormatedOptionValue($_option) ?>
<dt><?= $block->escapeHtml($_option['label']) ?></dt>
<dd>
<?php if (isset($_formatedOptionValue['full_view'])): ?>
<?= $block->escapeHtml($_formatedOptionValue['full_view'], ['span', 'a']) ?>
<?php else: ?>
<?= $block->escapeHtml($_formatedOptionValue['value'], ['span', 'a']) ?>
<?php endif; ?>
</dd>
<?php endforeach; ?>
</dl>
<?php endif;?>
<?php if ($messages = $block->getMessages()): ?>
<?php foreach ($messages as $message): ?>
<div class= "cart item message <?= $block->escapeHtmlAttr($message['type']) ?>">
<div><?= $block->escapeHtml($message['text']) ?></div>
</div>
<?php endforeach; ?>
<?php endif; ?>
<?php $addInfoBlock = $block->getProductAdditionalInformationBlock(); ?>
<?php if ($addInfoBlock): ?>
<?= $addInfoBlock->setItem($_item)->toHtml() ?>
<?php endif;?>
</div>
</td>
<?php if ($canApplyMsrp): ?>
<td class="col msrp" data-th="<?= $block->escapeHtml(__('Price')) ?>">
<span class="pricing msrp">
<span class="msrp notice"><?= $block->escapeHtml(__('See price before order confirmation.')) ?></span>
<?php $helpLinkId = 'cart-msrp-help-' . $_item->getId(); ?>
<a href="#" class="action help map"
id="<?= ($block->escapeHtmlAttr($helpLinkId)) ?>"
data-mage-init='{"addToCart":{
"origin": "info",
"helpLinkId": "#<?= $block->escapeJs($block->escapeHtml($helpLinkId)) ?>",
"productName": "<?= $block->escapeJs($block->escapeHtml($product->getName())) ?>",
"showAddToCart": false
}
}'>
<span><?= $block->escapeHtml(__("What's this?")) ?></span>
</a>
</span>
</td>
<?php else: ?>
<td class="col price" data-th="<?= $block->escapeHtml(__('Price')) ?>">
<?= $block->getUnitPriceHtml($_item) ?>
</td>
<?php endif; ?>
<td class="col qty" data-th="<?= $block->escapeHtml(__('Qty')) ?>">
<div class="field qty">
<label class="label" for="cart-<?= $block->escapeHtmlAttr($_item->getId()) ?>-qty">
<span><?= $block->escapeHtml(__('Qty')) ?></span>
</label>
<div class="control qty qty-controls-wrap">
<a class="icon-minus qty-minus"></a>
<a class="icon-plus qty-plus"></a>
<input id="cart-<?= $block->escapeHtmlAttr($_item->getId()) ?>-qty"
name="cart[<?= $block->escapeHtmlAttr($_item->getId()) ?>][qty]"
data-cart-item-id="<?= $block->escapeHtmlAttr($_item->getSku()) ?>"
value="<?= $block->escapeHtmlAttr($block->getQty()) ?>"
type="number"
min="0"
size="4"
step="any"
title="<?= $block->escapeHtmlAttr(__('Qty')) ?>"
class="input-text qty"
data-validate="{required:true,'validate-greater-than-zero':true}"
data-item-qty="<?= $block->escapeHtmlAttr($block->getQty()) ?>"
data-role="cart-item-qty"/>
</div>
</div>
</td>
<td class="col subtotal" data-th="<?= $block->escapeHtml(__('Subtotal')) ?>">
<?php if ($canApplyMsrp): ?>
<span class="cart msrp subtotal">--</span>
<?php else: ?>
<?= $block->getRowTotalHtml($_item) ?>
<?php endif; ?>
</td>
<td class="col actions" data-th="<?= $block->escapeHtml(__('Actions')) ?>">
<a href="#"
title="<?= $block->escapeHtmlAttr(__('Remove item')) ?>"
class="action action-delete"
data-post='<?= /* @noEscape */ $this->helper('Magento\Checkout\Helper\Cart')->getDeletePostJson($_item) ?>'>
<span>
<?= $block->escapeHtml(__('Remove item')) ?>
</span>
</a>
</td>
</tr>
<tr class="item-actions">
<td colspan="5">
<div class="actions-toolbar">
<?= /* @noEscape */ $block->getActions($_item) ?>
</div>
</td>
</tr>
</tbody>
@@ -0,0 +1,85 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
/** @var $block Sidebar */
/** @var SecureHtmlRenderer $secureRenderer */
use Magento\Checkout\Block\Cart\Sidebar;
use Magento\Framework\View\Helper\SecureHtmlRenderer;
$athlete = $this->helper('Olegnax\Athlete2\Helper\Helper');
$cartBtnText = __('Cart');
$cartAddedText = __('Product added to cart');
$moveSticky = '';
if( $athlete->getConfig( 'athlete2_settings/header/header_layout' ) === 'header_1'){
$moveSticky ='ox-move-sticky ox-move-sticky-header.main.right ox-move-item ox-move-item-header.main.right';
}
?>
<div data-block="minicart" class="minicart-wrapper <?= $block->escapeHtmlAttr($moveSticky) ?>">
<a class="action showcart" href="<?= $block->escapeUrl($block->getShoppingCartUrl()) ?>"
data-bind="scope: 'minicart_content'">
<img class="lts-header-icon lts-header-icon--cart"
src="<?= $block->escapeUrl($block->getViewFileUrl('Magento_Theme::images/lts-header/header_cart_icon.png')) ?>"
width="20" height="20" alt="" aria-hidden="true"/>
<span class="text"><?= $block->escapeHtml($cartBtnText) ?></span>
<span class="counter qty">
<span class="counter-number">
<!-- ko text: getCartParam('summary_count').toLocaleString(window.LOCALE) -->0<!-- /ko -->
</span>
</span>
</a>
<?php if ($block->getIsNeedToDisplaySideBar()):
$minicart_type = $athlete->getConfig( 'athlete2_settings/header/minicart_type' );
?>
<div class="block block-minicart empty"
data-role="OXmodalMinicart"
data-mage-init='{"OXmodalMinicart":{
"triggerTarget":".showcart",
"overlayClass":"ox-slideout-shadow",
"timeout": "500",
"closeButtonTrigger":"#btn-minicart-close",
"closeOnEscape": true,
"closeOnMouseLeave": <?php echo 'dropdown-hover' == $block->escapeHtmlAttr($minicart_type) ? 'true' : 'false'; ?>,
"hoverOpen": <?php echo 'dropdown-hover' == $block->escapeHtmlAttr($minicart_type) ? 'true' : 'false'; ?>,
"type": "<?php echo 'slideout' == $block->escapeHtmlAttr($minicart_type) ? 'slideout' : ''; ?>",
"positionSlideout": "right",
"htmlClass":"ox-fixed"
}}'>
<div id="minicart-content-wrapper" data-bind="scope: 'minicart_content'">
<div class="message success"><span class="text"><?= $block->escapeHtml(__($cartAddedText)) ?></span></div>
<?php
$promo = $block->getLayout()->createBlock( 'Magento\Cms\Block\Block' )->setBlockId( 'athlete_cart_promotion' )->toHtml();
if ( !empty( $promo ) ) :
?>
<div class="athlete_cart_promotion-content"><?php echo $promo; ?></div>
<?php endif; ?>
<!-- ko template: getTemplate() --><!-- /ko -->
</div>
<?= $block->getChildHtml('minicart.addons') ?>
</div>
<?php else :?>
<?php $scriptString = <<<script
require(['jquery'], function ($) {
$('a.action.showcart').on('click', function() {
$(document.body).trigger('processStart');
});
});
script;
?>
<?= /* @noEscape */ $secureRenderer->renderTag('script', [], $scriptString, false); ?>
<?php endif ?>
<?= /* @noEscape */ $secureRenderer->renderTag('script', [], 'window.checkout = ' .
/* @noEscape */ $block->getSerializedConfig(), false); ?>
<script type="text/x-magento-init">
{
"[data-block='minicart']": {
"Magento_Ui/js/core/app": <?= /* @noEscape */ $block->getJsLayout() ?>
}
}
</script>
</div>
@@ -0,0 +1,32 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
/** @var $block Cart */
use Magento\Checkout\Block\Cart;
?>
<div class="cart-empty">
<?= $block->getChildHtml('checkout_cart_empty_widget') ?>
<div class="athlete2-icon-cart empty-cart-icon"></div>
<p class="cart-empty-big-text"><?= $block->escapeHtml(__('Your cart is empty.')) ?></p>
<p><?= $block->escapeHtml(
__(
'<a class="button" href="%1">Continue shopping.</a>',
$block->escapeUrl($block->getContinueShoppingUrl())
),
['a']
) ?>
</p>
<?= $block->getChildHtml('shopping.cart.table.after') ?>
</div>
<script type="text/x-magento-init">
{
"*": {
"Magento_Checkout/js/empty-cart": {}
}
}
</script>
@@ -0,0 +1,15 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
// phpcs:disable Magento2.Templates.ThisInTemplate
/** @var $block Cart */
use Magento\Checkout\Block\Cart;
?>
<h1 class="page-title"><span><?= $block->escapeHtml(__('Shopping Cart')) ?></span></h1>
@@ -0,0 +1,23 @@
<?php
$at_settings = $this->helper('Olegnax\Athlete2\Helper\Helper')->getConfig('athlete2_settings/header');
$header_classes = 'header--layout-' . substr($at_settings['header_layout'], -1);
if( $at_settings['header_fullwidth'] ) {
$header_classes .= ' header--full-width';
}
?>
<div class="page-header <?= $block->escapeHtmlAttr($header_classes) ?>">
<div class="sticky-wrapper">
<div class="container-fluid">
<div class="row">
<div class="col header__content-wrapper">
<div class="logo__container">
<?php echo $this->getChildHtml( "logo" ); ?>
</div>
<div class="flex-right flex-row">
</div>
</div>
</div>
</div>
</div>
</div>
@@ -0,0 +1,84 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
/** @var $block \Magento\Checkout\Block\Onepage */
/** @var \Magento\Framework\View\Helper\SecureHtmlRenderer $secureRenderer */
?>
<div id="checkout" data-bind="scope:'checkout'" class="checkout-container">
<div id="checkout-loader" data-role="checkout-loader" class="loading-mask" data-mage-init='{"checkoutLoader": {}}'>
<div class="loader">
<img src="<?= $block->escapeUrl($block->getViewFileUrl('images/loader-1.gif')) ?>"
alt="<?= $block->escapeHtmlAttr(__('Loading...')) ?>">
</div>
</div>
<?= /* @noEscape */ $secureRenderer->renderStyleAsTag("position: absolute;", "#checkout-loader img") ?>
<!-- ko template: getTemplate() --><!-- /ko -->
<script type="text/x-magento-init">
{
"#checkout": {
"Magento_Ui/js/core/app": <?= /* @noEscape */ $block->getJsLayout() ?>
}
}
</script>
<?php $serializedCheckoutConfig = /* @noEscape */ $block->getSerializedCheckoutConfig();
$scriptString = <<<script
window.checkoutConfig = {$serializedCheckoutConfig};
// Create aliases for customer.js model from customer module
window.isCustomerLoggedIn = window.checkoutConfig.isCustomerLoggedIn;
window.customerData = window.checkoutConfig.customerData;
script;
?>
<?= /* @noEscape */ $secureRenderer->renderTag('script', [], $scriptString, false) ?>
<?php $scriptString = <<<script
require([
'mage/url',
'Magento_Ui/js/block-loader'
], function(url, blockLoader) {
blockLoader("{$block->escapeJs($block->escapeUrl($block->getViewFileUrl('images/loader-1.gif')))}");
return url.setBaseUrl('{$block->escapeJs($block->escapeUrl($block->getBaseUrl()))}');
})
script;
?>
<?= /* @noEscape */ $secureRenderer->renderTag('script', [], $scriptString, false) ?>
</div>
<div id="shipping-address-tip-modal">
<div class="modal-body-content">
<?= $this->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('lts_shipping_notice')->toHtml(); ?>
</div>
</div>
<script type="text/javascript">
require([
"jquery",
"Magento_Ui/js/modal/modal"
],function($, modal) {
var options = {
type: 'popup',
responsive: true,
title: 'Shipping Notice',
modalClass: 'shipping_tip',
responsive: true,
buttons: [{
text: $.mage.__('Ok'),
class: '',
click: function () {
this.closeModal();
}
}]
};
// 美国之外不配送提示
var popup = modal(options, $('#shipping-address-tip-modal'));
setTimeout(() => {
var selectedAddress = $('.shipping-address-item.selected-item .shipping-address-country').text();
if(selectedAddress && selectedAddress !=='United States'){
$('#shipping-address-tip-modal').modal('openModal');
}
}, 5000);
});
</script>
@@ -0,0 +1,30 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
use Magento\Checkout\Block\Onepage\Success;
// @codingStandardsIgnoreFile
?>
<?php /** @var $block Success */ ?>
<div class="checkout-success">
<?php if ($block->getOrderId()):?>
<?php if ($block->getCanViewOrder()) :?>
<p class="your-order-is"><?= $block->escapeHtml(__('Your order number is: %1', sprintf('<a href="%s" class="order-number"><strong>%s</strong></a>', $block->escapeUrl($block->getViewOrderUrl()), $block->getOrderId())), ['a', 'strong']) ?></p>
<?php else :?>
<p class="your-order-is"><?= $block->escapeHtml(__('Your order # is: %1', sprintf('<span class="order-number">%s</span>', $block->getOrderId())), ['span']) ?></p>
<?php endif;?>
<p><?= $block->escapeHtml(__('We\'ll email you an order confirmation with details and tracking info.')) ?></p>
<?php endif;?>
<?= $block->getAdditionalInfoHtml() ?>
<div class="actions-toolbar">
<div class="primary">
<a class="action primary continue" href="<?= $block->escapeUrl($block->getContinueUrl()) ?>"><span><?= $block->escapeHtml(__('Continue Shopping')) ?></span></a>
</div>
</div>
</div>
@@ -0,0 +1,807 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
@cart-summary-padding: 35px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.cart.page-title-wrapper{
padding-bottom: 50px;
padding-top: 20px;
.lib-clearfix();
.page-title{
display: inline-block;
float: left;
margin-bottom: 20px;
}
.action.checkout{
float: right;
min-width: 30%;
padding: @button__padding__b;
}
}
//
// Empty cart
// ---------------------------------------------
.cart-empty{
max-width: 760px;
margin: 0 auto;
text-align: center;
padding: 60px 20px;
min-height: 70vh;
display: flex;
align-items: center;
flex-flow: column;
align-content: center;
justify-content: center;
.empty-cart-icon{
font-size: 126px;
text-align: center;
color: #ececec;
line-height: 1;
}
}
.cart-empty-big-text{
.lib-heading(h2);
.at-headings();
}
//
// Shopping cart
// ---------------------------------------------
// Summary block
.cart-summary,
.checkout-cart-index .cart-summar{
&:extend(.abs-add-box-sizing all);
.lib-css(background, @sidebar__background-color);
margin-bottom: @indent__m;
padding: @cart-summary-padding;
}
.cart-summary {
> .title {
display: block;
.lib-heading(h3);
.at-headings();
text-align: center;
margin-bottom: 30px;
margin-top: 10px;
}
.block {
&:extend(.abs-discount-block all);
margin-bottom: 0;
.item-options {
margin-left: 0;
}
.fieldset {
margin: 0 0 15px 0;
&.coupon{
margin-bottom: 35px;
.field{
margin-bottom: 5px;
}
button{
width: 100%;
}
}
.field {
margin: 0 0 15px;
}
.methods {
.field {
> .label {
display: inline;
}
}
}
}
.fieldset.estimate {
> .legend,
> .legend + br {
&:extend(.abs-no-display all);
}
}
}
.actions-toolbar {
> .primary {
button {
.ox-button();
.ox-button-primary();
}
}
}
&:extend(.abs-adjustment-incl-excl-tax all);
}
// Totals block
.cart-totals {
border-top: 1px solid @border-color__base;
padding-top: 20px;
padding-bottom: 20px;
font-weight: @font-weight__bold;
.table-wrapper {
margin-bottom: 0;
overflow: inherit;
}
.discount.coupon {
display: none;
}
}
table.table-totals,
table.totals{
font-weight: @font-weight__bold;
display: flex;
tbody{
width:100%;
tr{
display: flex;
&.grand.totals{
flex-flow: column;
th{
padding: 0;
padding-top: 20px;
text-transform: uppercase;
strong{
font-weight: @font-weight__black;
}
}
td{
padding: 0;
margin-left: 0;
}
.price{
font-size: 48px;
font-weight: @font-weight__black;
letter-spacing: -2px;
line-height: 1;
}
}
}
th{
padding: 4px 0;
padding-right: 10px;
}
td{
padding: 4px 0;
margin-left: auto;
display: inline-block;
}
}
}
// Products table
.multicheckout.address.form {
.table{
tbody{
td.col{
border-bottom: 1px solid #e5e5e5;
}
}
}
> .actions-toolbar{
display: block;
> .primary{
border-bottom: 1px solid #e5e5e5;
padding-bottom: 30px;
margin-bottom: 30px;
}
}
}
.multicheckout.address.form .table-wrapper .table,
.cart.table-wrapper {
.items {
thead{
background: @sidebar__background-color;
text-transform: uppercase;
}
/*thead + .item {
border-top: @border-width__base solid @border-color__base;
}*/
> .item {
border-bottom: @border-width__base solid #e5e5e5;
position: relative;
}
}
.col {
padding: 26px 14px;
vertical-align: middle;
&:first-child{
padding-left:32px;
}
&:last-child{
padding-right:32px;
}
&.actions{
padding-right: 10px;
span{
display:none;
}
.action{
width: 27px;
height: 26px;
display: inline-block;
&.delete,
&.action-delete{
.lib-icon-font(
@icon-remove,
@_icon-font-size: 12px,
@_icon-font-line-height: 26px,
@_icon-font-text-hide: true,
@_icon-font-color: #000000,
@_icon-font-color-hover: #ffffff,
@_icon-font-color-active: #ffffff
);
background: transparent;
padding:0;
&:after,
&:before{
.lib-css(transition, ~"all 600ms ease-in-out", @_prefix: 1);
}
&:before{
position: relative;
left: 0;
top: 0px;
width: 100%;
}
&:hover{
background: #000000;
&:after,
&:before{
.lib-css(transition, ~"all 10ms ease-in-out", @_prefix: 1);
}
}
}
}
}
&.qty {
.input-text {
height: 46px;
text-align: center;
width: 100%;
min-width: 80px;
padding: 0 22px;
padding-bottom: 1px;
background: @color-gray-light01;
border: none;
font-size: 18px;
font-weight: @font-weight__bold;
}
.icon-minus,
.icon-plus{
width: 24px;
height: 46px;
}
.label {
&:extend(.abs-visually-hidden all);
}
}
}
.item {
&-actions td {
padding-bottom: 10px;
padding-top: 0;
text-align: center;
white-space: normal;
}
.col {
&.item {
display: block;
min-height: 75px;
padding-left: 0;
position: relative;
}
}
}
.actions-toolbar {
&:extend(.abs-add-clearfix all);
> .action {
//&:extend(button all);
//.lib-link-as-button();
float:left;
text-transform:uppercase;
margin-bottom: 5px;
margin-right: 5px;
padding: 6px 7px;
font-size: 12px;
background: @main-color;
color:#000;
font-weight:800;
&.action-delete,
&.action-edit{
display:none;
}
&:last-child {
margin-right: 0;
}
}
}
.action {
&.help.map {
&:extend(.abs-action-button-as-link all);
font-weight: @font-weight__regular;
}
}
.product {
&-item-photo {
display: block;
left: 0;
max-width: 60px;
padding: 0;
position: absolute;
top: 15px;
width: 100%;
}
&-item-details {
white-space: normal;
}
&-item-name {
display: inline-block;
font-weight: @font-weight__black;
font-size: 16px;
text-transform: uppercase;
> a{
font-weight: inherit;
}
}
}
.gift-registry-name-label {
&:after {
content: ':';
}
}
// Product options
.item-options {
text-transform: uppercase;
font-weight: @font-weight__bold;
line-height: 1;
&:extend(.abs-product-options-list all);
&:extend(.abs-add-clearfix all);
margin-bottom: 0;
}
.product-image-wrapper {
&:extend(.abs-reset-image-wrapper all);
}
.action.configure {
display: inline-block;
margin: 0 0 @indent__base;
}
}
.cart-container {
.form-cart {
margin-bottom: 30px;
&:extend(.abs-shopping-cart-items all);
.table-wrapper{
margin-bottom:40px;
}
}
.checkout-methods-items {
&:extend(.abs-reset-list all);
background: #000;
margin: 10px -@cart-summary-padding -@cart-summary-padding;
padding: @cart-summary-padding;
text-align: center;
.action.primary {
&:extend(.abs-button-l all);
width: 100%;
}
.item {
& + .item {
margin-top: @indent__base;
}
}
.action.multicheckout{
color: #fff;
text-transform: uppercase;
font-weight: @font-weight__bold;
letter-spacing: -0.03em;
}
}
}
// Products pager
.cart-products-toolbar {
.toolbar-amount {
margin: @indent__m 0 15px;
padding: 0;
text-align: center;
}
.pages {
margin: 0 0 @indent__m;
text-align: center;
.items {
> .item {
border-bottom: 0;
}
}
}
}
.cart-products-toolbar-top {
margin-bottom: 25px;
/*border-bottom: @border-width__base solid @border-color__base;*/
}
//
// Cross sell
// ---------------------------------------------
.block.crosssell {
margin-top: 70px;
}
.cart-tax-info,
.cart .cart-tax-info {
+ .cart-tax-total {
display: block;
}
}
.multicheckout.address.form .table-wrapper .table,
.cart.table-wrapper,
.order-items.table-wrapper {
.col.price,
.col.qty,
.col.subtotal,
.col.msrp {
text-align: center;
}
.col.address{
text-align: right;
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__xs) {
.cart-summary{
padding: 25px;
margin-bottom:0;
margin-left: -15px;
margin-right: -15px;
}
.cart-container .checkout-methods-items{
margin: 0 -25px -25px;
padding: 25px;
}
table{
&.table-totals,
&.totals {
tbody tr.grand.totals .price{
font-size: 34px;
}
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.cart.page-title-wrapper{
padding-bottom: 30px;
}
.cart-container .form-cart .actions{
.action{
width:100%;
margin: 0 0 10px 0;
}
}
.cart {
&.table-wrapper {
overflow: inherit;
thead {
.col {
display: none!important;
/*&:not(.item) {
display: none;
}*/
}
}
.col {
padding: 16px 10px;
&.price,
&.subtotal,
&.msrp {
/*box-sizing: border-box;
display: block;
float: left;
text-align: center;
white-space: nowrap;
width: 33%;*/
&[data-th]:before {
content: attr(data-th) ':';
display: block;
font-weight: @font-weight__bold;
padding-bottom: @indent__s;
}
}
&.price{
text-align: left;
}
&.subtotal{
text-align: right;
}
&.msrp {
white-space: normal;
text-align: center;
}
&.actions{
position: absolute;
top: 30px;
right: 5px;
display: block;
width: 30px;
height: 30px;
padding: 0;
}
}
.product-item-photo{
position: static;
margin-right: 30px;
max-width: initial;
width: auto;
}
.item {
.col.item {
width: 100%;
min-width: 100%;
display: flex;
position: relative;
padding: 26px 40px 0 0;
}
.item-info{
display: flex;
flex-wrap: wrap;
position: relative;
align-items: center;
}
}
}
}
.cart-container {
.form-cart {
&:extend(.abs-shopping-cart-items-mobile all);
}
}
}
@media (max-width:767px){
.cart.page-title-wrapper{
padding-top: 0;
.page-title{
float: none;
text-align: center;
}
.action.checkout{
float: none;
width:100%;
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__m) {
.cart-container{
display: flex;
flex-flow: column;
.cart-summary{
order: 2;
}
.form-cart{
order: 1;
}
}
}
//
// Small mobile to Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__s) {
.multicheckout.address.form{
.col.address{
select{
width:auto;
max-width: 300px;
}
}
}
.cart-empty-big-text{
.lib-heading(h1);
.lib-css(margin-bottom, @h1__margin-bottom__desktop);
}
.cart-empty{
.empty-cart-icon{
.lib-css(margin-bottom, @h1__margin-bottom__desktop);
}
}
.cart {
&.table-wrapper {
.items { // Google Chrome version 44.0.2403.107 m fix
min-width: 100%;
width: auto;
}
.item {
&-actions {
td {
text-align: right;
}
}
}
.product {
&-item-photo {
display: table-cell;
max-width: 100%;
padding-right: 30px;
position: static;
vertical-align: top;
width: 1%;
}
&-item-details {
display: table-cell;
vertical-align: middle;
white-space: normal;
width: 99%;
}
}
.item-actions {
.actions-toolbar {
text-align: left;
&:extend(.abs-reset-left-margin-desktop all);
}
}
}
&.main.actions{
.action {
margin-bottom: 10px;
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.multicheckout.address.form{
.col.address{
select{
max-width: 100%;
}
}
}
.cart.main.actions{
text-align:right;
.action.continue{
float: left;
}
}
.cart-container {
&:extend(.abs-add-clearfix-desktop all);
.form-cart {
/*&:extend(.abs-shopping-cart-items-desktop all);*/
width: 70%;
padding-right: 50px;
float: left;
position: relative;
}
.widget {
float: left;
}
}
.cart-summary {
float: right;
position: relative;
width: 30%;
.actions-toolbar {
.column.main & {
&:extend(.abs-reset-left-margin-desktop all);
> .secondary {
float: none;
}
}
}
.block {
.fieldset {
.field {
/*.lib-form-field-type-revert(@_type: block);*/
}
}
}
}
// Products pager
.cart-products-toolbar {
.toolbar-amount {
line-height: 30px;
margin: 0;
}
.pages {
float: right;
margin: 0 0 1px;
.item {
&:last-child {
margin-right: 0;
}
}
}
}
.multicheckout.address.form .table-wrapper .table,
.cart.table-wrapper {
.cart {
+ .cart-products-toolbar {
margin-top: @indent__m;
}
}
}
}
//
// Desktop Small
// _____________________________________________
@media (min-width:@screen__m) and (max-width:@screen__l){
.cart-container {
.form-cart{
padding-right: 30px;
width: 67%;
}
.checkout-methods-items {
margin: 10px -25px -25px;
padding: 25px;
}
}
.multicheckout.address.form .table-wrapper .table,
.cart.table-wrapper {
.product-item-photo{
padding-right: 20px;
}
.cart.table-wrapper .col{
padding: 22px 10px;
}
}
.cart-summary{
padding: 25px;
width: 33%;
}
}
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,281 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@block-auth__dropdown__padding: @indent__m;
@block-auth__dropdown__background-color: @color-white;
@block-auth__or-label__size: 44px;
@block-auth__width: 0;
@block-auth__border: none;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.popup-authentication {
&.modal-popup {
.modal-header {
background:none;
padding: 0;
position: absolute;
right: 0px;
top: 0;
z-index: 2;
}
.modal-content{
padding: 0;
}
.block-authentication {
.block[class] {
padding:55px;
}
}
}
}
.authentication-dropdown {
box-sizing: border-box;
.modal-inner-wrap {
padding: 55px;
}
&.modal-custom .action-close{
margin: 0;
}
}
.authentication-wrapper {
/* temp */
position: absolute;
top: 11px;
z-index: 2;
right: 15px;
/* float: right;
max-width: 50%;
position: relative;
z-index: 1;*/
._has-auth-shown & {
z-index: @modal__z-index;
}
}
.block-authentication {
display: flex;
flex-flow: column;
.block-title {
strong{
.lib-font-size(@h3__font-size);
}
border-bottom: 0;
margin-bottom: @indent__m;
}
.actions-toolbar {
display: flex;
align-items: center;
justify-content: center;
flex-flow: wrap;
> .primary {
.action{
padding: @button__padding__b;
min-width: 150px;
}
}
> .secondary {
> a.action{
background: none;
color: #000;
padding: 5px 7px;
font-size:12px;
margin-bottom: 10px;
margin-top: 10px;
}
}
}
.block-new-customer{
background: #f8f8f8;
order: 2;
}
.block[class] {
margin: 0;
ul {
list-style: square;
padding-left: 20px;
list-style-position: inside;
}
.field {
.control,
.label {
float: none;
width: auto;
}
}
&.block-new-customer {
position: relative;
&:before {
.lib-css(height, @block-auth__or-label__size);
.lib-css(line-height, @block-auth__or-label__size - 2px);
.lib-css(margin, -(@block-auth__or-label__size/2 + 1px) 0 0 -(@block-auth__or-label__size / 2));
.lib-css(min-width, @block-auth__or-label__size);
background: @color-black;
border: none;
border-radius: 0;
box-sizing: border-box;
color: @color-white;
font-weight:800;
content: attr(data-label);
display: inline-block;
left: 50%;
letter-spacing: normal;
padding: 0 .2rem;
position: absolute;
text-align: center;
text-transform: uppercase;
top: 0;
}
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.authentication-dropdown {
.lib-css(background-color, @block-auth__dropdown__background-color);
.lib-css(border, none);
-webkit-transition: opacity .2s, visibility 0s linear .1s;
position: absolute;
text-align: left;
top: 100%;
opacity:0;
transition: transform linear .1s, visibility 0s linear .1s;
visibility: hidden;
width: 100%;
min-width: 460px;
right: 0;
&._show {
.lib-css(z-index, @dropdown-list__z-index);
opacity:1;
visibility: visible;
}
}
.authentication-wrapper {
/*.lib-column-width(@checkout-sidebar__columns);
text-align: right;*/
}
.block-authentication {
.block-title {
strong{
.lib-font-size(@h2__font-size);
}
border-bottom: 0;
margin-bottom: @indent__m;
}
.block-new-customer{
.actions-toolbar {
> .primary {
float: none;
}
}
}
}
.popup-authentication {
.modal-inner-wrap {
min-width: @screen__m;
width: 60%;
}
.block-authentication {
.lib-vendor-prefix-display(flex);
.lib-vendor-prefix-flex-direction(row);
}
.block[class],
.form-login,
.fieldset,
.block-content {
.lib-vendor-prefix-display(flex);
.lib-vendor-prefix-flex-direction(column);
.lib-vendor-prefix-flex-grow(1);
}
.block[class] {
flex-flow: wrap;
align-self: stretch;
align-content: center;
box-sizing: border-box;
float: left;
width: 50%;
&.block-new-customer {
&:before {
left: 0;
top: 50%;
}
}
}
.actions-toolbar {
margin-bottom: 0;
margin-top: auto;
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.block-title {
strong{
.lib-font-size(@h3__font-size-mobile);
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__xs) {
.authentication-dropdown {
box-sizing: border-box;
.modal-inner-wrap {
padding: 35px;
}
}
.block-authentication{
.actions-toolbar {
flex-flow: column;
> .primary {
width: 100%;
.action{
width: 100%;
}
}
}
}
.popup-authentication {
&.modal-popup {
.block-authentication{
.block[class] {
padding: 35px;
&.block-new-customer{
padding-top: 50px;
}
&.block-customer-login{
padding-bottom: 50px;
}
}
}
}
}
}
@@ -0,0 +1,38 @@
//
// Common
// _____________________________________________
& when (@media-common = true) {
.payment-method-braintree.payment-method {
.cvv {
max-width: 220px;
position: relative;
.field-tooltip {
top: 12px;
right: @indent__l;
}
}
.hosted-control{
box-sizing:content-box;
}
.braintree-credit-card-selected {
position: absolute;
z-index: 10;
left: 10px;
}
}
.inputs-style--underlined{
.payment-method-braintree.payment-method {
.fieldset {
> .field,
> .fields > .field {
.label {
margin-bottom:5px;
}
}
}
}
}
}
@@ -0,0 +1,70 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Common
// _____________________________________________
& when (@media-common = true) {
.checkout-agreements-block {
.checkout-agreements {
margin-bottom: @indent__base;
.checkout-agreement{
display: flex;
}
}
.action-show {
&:extend(.abs-action-button-as-link all);
vertical-align: baseline;
font-weight: @font-weight__black;
text-transform: uppercase;
position: relative;
white-space: normal;
text-align: left;
&:after{
content:none!important;
}
}
}
// Checkout Agreements in popup
.checkout-agreements-items {
&:extend(.abs-reset-list all);
padding-bottom: @indent__l;
.checkout-agreements-item {
margin-bottom: @indent__base;
}
.checkout-agreements-item-title {
&:extend(.abs-checkout-title all);
border-bottom: 0;
}
}
// Checkout Agreements
.checkout-agreement-item-content {
overflow: auto;
}
.modal-popup {
&.agreements-modal{
.modal-header{
background: none;
padding: 0;
}
}
}
}
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @modal-popup-breakpoint-screen__m) {
.modal-popup {
&.agreements-modal{
.modal-content{
padding: 40px;
}
}
}
}
@@ -0,0 +1,361 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
@import "_braintree.less";
//
// Variables
// _____________________________________________
@checkout-wrapper__margin: @indent__base;
@checkout-wrapper__columns: 8;
@checkout-step-title__border: @border-width__base solid @color-gray80;
@checkout-step-title__font-size: 36px;
@checkout-step-title__font-weight: @font-weight__bold;
@checkout-step-title__padding: @indent__s;
@checkout-step-title-mobile__font-size: 26px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.payment-method-braintree .hosted-control{
box-sizing:content-box;
}
#tooltip-label{
display:none;
}
body{
/*&.checkout-index-index,*/
&.multishipping-checkout-success,
&.checkout-onepage-success{
background: #f8f8f8;
}
}
.checkout-index-index{
.page-main{
max-width: 100%;
}
}
.multishipping-checkout-success,
.checkout-onepage-success{
.page-title-wrapper{
max-width: 500px;
padding: 0 40px;
margin: 0 auto;
text-align: center;
display: flex;
flex-flow: column;
.page-title{
margin-bottom:40px;
order: 2;
}
.success-icon-wrapper{
order: 1;
width: 120px;
height: 120px;
display: block;
overflow: hidden;
position: relative;
left: 50%;
margin-left: -60px;
margin-bottom: 40px;
&:before {
content: '';
position: absolute;
display: block;
background: #a4cf29;
width: 100%;
height: 100%;
top: 0;
left: 0;
transform: scaleX(0);
transform-origin: 0;
animation: transform-0-1 0.5s;
animation-delay: 0.15s;
animation-fill-mode: forwards;
animation-timing-function: cubic-bezier(0.68, -0.01, 0, 1.01);
}
.success-icon{
width: 100%;
height: 100%;
display: block;
position: absolute;
&:before,
&:after{
content: '';
display: inline-block;
overflow: hidden;
background: #ffffff;
position: absolute;
top: 50%;
left:50%;
width: 25px;
}
&:before{
height: 6px;
margin-top: -7px;
margin-left: -20px;
transform: rotate(45deg) scaleX(0);
transform-origin: 0;
animation: checkboxleft 0.4s;
animation-delay: 0.8s;
animation-fill-mode: forwards;
}
&:after{
width: 37px;
margin-left: -4px;
margin-top: 8px;
height: 6px;
transform: rotate(-45deg) scaleX(0);
transform-origin: 0;
animation: checkboxright 0.6s;
animation-delay: 1.2s;
animation-fill-mode: forwards;
}
}
}
}
}
.checkout-success-wrapper{
max-width: 500px;
margin: 0 auto;
padding: 55px;
box-shadow: 0px 15px 70px -8px rgba(0, 0, 0, 0.11);
background: #ffffff;
.multicheckout.success,
.checkout-success{
.your-order-is{
font-weight: @font-weight__bold;
text-transform: uppercase;
.order-number{
display: block;
background: #f8f8f8;
padding: 10px 20px;
margin-top: 10px;
font-weight: @font-weight__black;
font-size: 18px;
}
}
}
#registration{
margin-top: 30px;
padding: 30px;
background: #f8f8f8;
br {
display: none;
}
}
}
.checkout-index-index {
.page-title-wrapper {
&:extend(.abs-visually-hidden all);
}
.page-main{
padding: 50px 50px 20px 50px;
}
}
.checkout-container {
&:extend(.abs-add-clearfix all);
.lib-css(margin, 0 0 @checkout-wrapper__margin);
}
.opc-wrapper {
.lib-css(margin, 0 0 @checkout-wrapper__margin);
.opc-wrapper-boxed{
padding: 50px;
padding-top: 40px;
box-shadow: 0px 15px 70px -8px rgba(0, 0, 0, 0.11);
background: #ffffff;
align-self: stretch;
height: 100%;
}
.opc {
&:extend(.abs-reset-list all);
}
.form{
fieldset{
legend.label{
margin-bottom: 10px;
padding: 0;
}
}
}
.step-title {
&:extend(.abs-checkout-title all);
.lib-css(font-size, @checkout-step-title__font-size);
margin-bottom:10px;
margin-top:50px;
}
.step-content {
margin: 0;
}
}
.checkout-index-index {
.nav-sections,
.nav-toggle {
display: none;
}
.logo {
margin-left: 0;
}
}
.checkout-onepage-success {
&:extend(.abs-add-clearfix all);
.print {
display: none;
}
}
/* discount form */
.opc-wrapper {
form.form-discount {
max-width: 100%;
display: flex;
width: 100%;
.payment-option-inner{
width: 100%;
padding-right: 20px;
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.opc-wrapper {
.step-title {
.lib-css(font-size, @checkout-step-title-mobile__font-size);
border-bottom: 0;
padding-bottom: 0;
}
.opc-wrapper-boxed{
padding: 30px;
padding-top: 20px;
}
}
.checkout-index-index {
.page-main{
padding: 30px 30px 0 30px;
}
.modal-popup.modal-slide.shipping_tip {
left: 5%;
width: 90%;
height: auto;
bottom: auto;
top: 50%;
transform: translateY(-50%);
.modal-inner-wrap {
height: auto;
}
}
}
.multishipping-checkout-success,
.checkout-onepage-success {
.page-title-wrapper{
padding: 0;
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__xs) {
.checkout-success-wrapper{
padding: 30px;
#registration{
padding: 30px;
}
}
.opc-wrapper {
.opc-wrapper-boxed{
padding: 20px;
padding-top: 15px;
}
}
.checkout-index-index {
.page-main{
padding: 30px 15px 0 15px;
}
}
.opc-wrapper {
form.form-discount {
flex-flow: column;
.payment-option-inner{
padding-right: 0;
}
.actions-toolbar{
.action{
width: 100%;
margin-top: 15px;
}
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.multishipping-checkout-success,
.checkout-onepage-success{
.column.main{
display: flex;
align-items: center;
min-height: 70vh;
}
}
.checkout-index-index {
.page-main{
padding:50px 50px 30px 50px;
}
}
.opc-wrapper {
&:extend(.abs-add-box-sizing-desktop-m all);
width: 60%;
float: left;
-ms-flex-order: 1;
-webkit-order: 1;
order: 1;
padding-right: 50px;
.opc-wrapper-boxed{
padding: 50px;
padding-top: 50px;
}
}
.multishipping-checkout-success,
.checkout-onepage-success {
.print {
display: none;
font-weight: @font-weight__semibold;
margin: 22px 0 0;
border-bottom: 2px solid;
}
}
}
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__ml) {
.checkout-index-index {
.page-main{
padding: 70px 70px 40px 70px;
}
}
.opc-wrapper {
padding-right: 80px;
.opc-wrapper-boxed {
padding: 70px;
padding-top: 50px;
}
}
}
@@ -0,0 +1,85 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
@checkout-step-title-mobile__font-size: 20px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
//
// Checkout Estimated Total
// ---------------------------------------------
.minicart-btn__icon--hide:not(.minicart-btn--minimal) .opc-estimated-wrapper .action.showcart svg{
display: block;
}
.opc-estimated-wrapper {
&:extend(.abs-add-clearfix all);
&:extend(.abs-no-display-desktop all);
margin: 0 0 40px 0;
.estimated-block {
.lib-css(font-size, @checkout-step-title-mobile__font-size);
.lib-css(font-weight, @font-weight__bold);
float: left;
text-transform: uppercase;
line-height: 1;
.estimated-label {
display: block;
}
.estimated-price{
font-size: 36px;
}
}
.minicart-wrapper {
.action {
&.showcart {
float: right;
padding: 0 22px;
height: 47px;
svg{
margin-right: 0px;
}
&:before {
.lib-css(color, @button__color);
}
&:hover:before {
.lib-css(color, @button__hover__color);
}
}
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.opc-estimated-wrapper {
margin: 0 0 30px 0;
.minicart-wrapper .action.showcart{
padding: 0 15px;
height: 40px;
}
.estimated-block {
font-size: 16px;
.estimated-price{
font-size: 30px;
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.opc-estimated-wrapper {
display: none;
margin: 50px 0 0 0;
}
}
@@ -0,0 +1,56 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-field-validation__border-color: @form-element-validation__border-error;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.field {
.control {
&._with-tooltip {
&:extend(.abs-field-tooltip all);
}
}
&.choice {
.field-tooltip {
display: inline-block;
margin-left: @indent__s;
position: relative;
top: -3px;
}
.field-tooltip-action {
.lib-css(line-height, @checkout-tooltip-icon__font-size);
}
}
&._error {
.control {
input,
select,
textarea {
.lib-css(border-color, @checkout-field-validation__border-color);
}
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
}
@@ -0,0 +1,78 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-modal-popup__width: 800px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.checkout-index-index {
.modal-popup {
.field-tooltip {
.field-tooltip-content {
&:extend(.abs-checkout-tooltip-content-position-top all);
}
}
.modal-footer {
.action-save-address,
.action-hide-popup{
width:100%;
margin-bottom: 10px;
}
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.checkout-index-index {
.modal-popup {
.form-shipping-address {
.lib-css(max-width, @checkout-shipping-address__max-width);
}
.modal-footer {
.action-save-address {
float: right;
margin: 0;
width:auto;
+ .action-hide-popup{
float: left;
}
}
.action-hide-popup{
margin: 0;
width:auto;
}
.action-hide-popup {
&:extend(.abs-action-button-as-link all);
}
}
}
}
}
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__l) {
.checkout-index-index {
.modal-popup {
.modal-inner-wrap {
.lib-css(margin-left, -(@checkout-modal-popup__width/2));
.lib-css(width, @checkout-modal-popup__width);
left: 50%;
}
}
}
}
@@ -0,0 +1,312 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-summary__background-color: transparent;
@checkout-summary__padding: 0;
@checkout-summary-title__margin: @indent__s;
@checkout-summary-mark-value__color: @color-gray60;
@checkout-summary-items__max-height: 370px;
@checkout-summary-items__padding: 15px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
//
// Order Summary
// ---------------------------------------------
.opc-block-summary {
&:extend(.abs-add-box-sizing all);
.lib-css(background, @checkout-summary__background-color);
.lib-css(padding, @checkout-summary__padding);
> .title {
&:extend(.abs-checkout-title all);
font-size: 3.6rem;
margin-bottom: 30px;
margin-top: 5px;
}
.message.success{
&:before{
width: 100%;
z-index: -1;
padding-left: 20px;
text-align: center;
}
}
// Totals table
.table-totals {
&:extend(.abs-sidebar-totals all);
margin-bottom: 30px;
}
.mark {
.value {
.lib-css(color, @checkout-summary-mark-value__color);
display: block;
}
}
.discount.coupon {
display: none;
}
.grand.incl {
& + .grand.excl {
.mark,
.amount {
border-top: 0;
.lib-font-size(14);
padding-top: 0;
strong {
font-weight: @font-weight__regular;
}
}
}
}
.not-calculated {
font-style: italic;
}
//
// Items list
// ---------------------------------------------
// Block title
.items-in-cart {
&:extend(.abs-discount-block all);
/*> .title {
border-top: @border-width__base solid @border-color__base;
.lib-css(padding, 30px 40px 0 0);
cursor: pointer;
.lib-icon-font(
@icon-down,
@_icon-font-size: 30px,
@_icon-font-line-height: 12px,
@_icon-font-text-hide: true,
@_icon-font-margin: 3px 0 0,
@_icon-font-position: after,
@_icon-font-display: block
);
margin-bottom: 0;
position: relative;
&:after {
position: absolute;
right: 0;
}
}
&.block{
> .title {
strong {
span{
.lib-font-size(18);
margin: 0;
}
}
}
}
&.active {
> .title {
.lib-icon-font-symbol(
@_icon-font-content: @icon-up,
@_icon-font-position: after
);
}
}*/
.product {
position: relative;
}
}
// Cart items
.minicart-items-wrapper {
.lib-css(margin, 0);
/*.lib-css(max-height, @checkout-summary-items__max-height);*/
border: 0;
}
.column.main & {
.product-item {
margin: 0;
background: none;
padding: 0;
padding-bottom: 30px;
}
}
.product-item {
padding: 20px 0;
.product{
display: flex;
width: 100%;
}
.product-item-inner {
display: table;
margin: 0 0 @indent__s;
width: 100%;
}
dl.item-options{
margin-top: 7px;
margin-bottom: 7px;
display: flex;
flex-wrap: wrap;
width: 100%;
dt{
width: 50%;
font-size: 13px;
text-transform: uppercase;
line-height: 1;
}
dd{
font-weight: @font-weight__semibold;
line-height: 1;
width: 50%;
}
}
.product-item-details {
> .product.options{
margin-top: 7px;
}
.product.options{
flex-wrap: wrap;
margin-top: 10px;
.field.configurable{
margin: 10px 0;
}
}
.price-excluding-tax{
margin:0;
> span{
display: block;
}
}
}
.details-qty{
font-weight: @font-weight__bold;
.label{
word-break: initial;
}
}
.product-item-name-block {
display: table-cell;
padding-right: @indent__xs;
text-align: left;
}
.product-item-name{
margin-left: 0;
max-width: 100%;
}
.subtotal {
vertical-align: top;
display: table-cell;
text-align: right;
}
.price-including-tax {
& + .price-excluding-tax {
margin: 0;
.price {
.lib-font-size(10);
}
}
}
}
.actions-toolbar {
position: relative;
z-index: 1;
.secondary {
border-top: @border-width__base solid @border-color__base;
display: block;
float: none;
margin: -1px 0 0;
padding: 15px 0 0;
text-align: left;
.action {
margin: 0;
}
}
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__m) {
.opc-summary-wrapper.custom-slide {
.modal-inner-wrap{
padding: 50px;
}
.action-close{
margin:0;
}
.opc-block-summary {
> .title{
font-size: 2.8rem;
margin-bottom: 20px;
margin-top: 0;
}
.product-item {
.product-item-inner{
display: block
}
.subtotal{
display: block;
text-align: left;
}
.product-item-name-block{
display: block;
}
}
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__xs) {
.opc-summary-wrapper.custom-slide {
.modal-inner-wrap{
padding: 30px;
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.opc-summary-wrapper {
.modal-header {
.action-close {
display: none;
}
}
.modal-inner-wrap{
box-shadow:none;
}
}
.opc-block-summary .product-item .subtotal .price-including-tax{
margin:0;
> span{
justify-content: flex-end;
}
}
}
@@ -0,0 +1,239 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-payment-option-title__border: @checkout-payment-method-title__border;
@checkout-payment-option-title__color: @link__color;
@checkout-payment-option-title__padding: @checkout-payment-method-title__padding;
@checkout-payment-option-title-mobile__padding: @checkout-payment-method-title-mobile__padding;
@checkout-payment-option-title-icon__font-size: 32px;
@checkout-payment-option-title-icon__line-height: 16px;
@checkout-payment-option-title-icon__margin: 0;
@checkout-payment-option-title-icon__color: @minicart-icons-color;
@checkout-payment-option-title-icon__hover__color: @primary__color;
@checkout-payment-option-content__padding__xl: @checkout-payment-method-content__padding__xl;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.checkout-payment-method {
.payment-option {
&._active {
.payment-option-title {
.lib-icon-font-symbol(
@_icon-font-content: '\74',
@_icon-font-position: after
);
}
}
&._collapsible {
&:extend(.abs-discount-block all);
.payment-option-title {
cursor: pointer;
}
.payment-option-content {
display: none;
}
}
}
.payment-option-title {
cursor: pointer;
font-weight: @font-weight__bold;
.lib-icon-font(
@_icon-font-content: '\75',
@_icon-font: 'Athlete2',
@_icon-font-line-height: 24px,
@_icon-font-color: #000,
@_icon-font-color-hover: #fff,
@_icon-font-size: 12px,
@_icon-font-text-hide: false,
@_icon-font-position: after,
@_icon-font-display: block
);
margin-bottom: 0;
overflow: hidden;
.lib-css(padding, 30px 30px 30px 0);
position: relative;
span{
.lib-font-size(18);
.at-headings();
font-weight:800;
}
&:after {
position: absolute;
right: 0;
top: 28px;
width: 24px;
height: 24px;
-webkit-transition: all 600ms ease-in-out;
-moz-transition: all 600ms ease-in-out;
-o-transition: all 600ms ease-in-out;
transition: all 600ms ease-in-out;
}
&:hover{
&:after {
-webkit-transition: all 10ms ease-in-out;
-moz-transition: all 10ms ease-in-out;
-o-transition: all 10ms ease-in-out;
transition: all 10ms ease-in-out;
background: #000;
}
}
//.lib-css(border-top, @checkout-payment-option-title__border);
//.lib-css(padding, @checkout-payment-option-title__padding 0);
/*.action-toggle {
.lib-css(color, @checkout-payment-option-title__color);
.lib-icon-font(
@icon-down,
@_icon-font-size: @checkout-payment-option-title-icon__font-size,
@_icon-font-line-height: @checkout-payment-option-title-icon__line-height,
@_icon-font-color: @checkout-payment-option-title-icon__color,
@_icon-font-color-hover: @checkout-payment-option-title-icon__hover__color,
@_icon-font-color-active: @checkout-payment-option-title-icon__color,
@_icon-font-margin: @checkout-payment-option-title-icon__margin,
@_icon-font-position: after
);
}*/
}
/*
.payment-option-content {
.lib-css(padding, 0 0 @indent__base @checkout-payment-option-content__padding__xl);
}*/
/*
.payment-option-inner {
margin: 0 0 @indent__base;
}*/
.credit-card-types {
padding: 0;
.item {
display: inline-block;
list-style: none;
margin: 0 @indent__xs 0 0;
vertical-align: top;
&._active {
font-weight: @font-weight__bold;
img {
-webkit-filter: grayscale(0%);
}
}
&._inactive {
opacity: .4;
}
span {
display: inline-block;
padding-top: 6px;
vertical-align: top;
}
}
img {
-webkit-filter: grayscale(100%); // For Webkit browsers
-webkit-transition: all .6s ease; // Fade to color for Chrome and Safari
}
}
.ccard {
.legend {
&:extend(.abs-visually-hidden all);
}
.fields {
> .year {
padding-left: @indent__xs;
}
.select {
padding-left: @indent__xs;
padding-right: @indent__xs;
}
}
.month {
.select {
width: 140px;
}
}
.year {
.select {
width: 80px;
}
}
.number {
.input-text {
width: 225px;
}
}
> .field.cvv {
> .control {
padding-right: @indent__base;
width: auto;
}
}
.cvv {
.input-text {
width: 55px;
}
}
&.fieldset {
> .field {
.fields.group.group-2 {
.field {
width: auto !important;
}
}
}
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__m) {
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.checkout-payment-method {
.payment-option-content {
.payment-option-inner {
+ .actions-toolbar {
margin-left: 0;
}
}
}
}
}
@@ -0,0 +1,248 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-payment-method-title__border: @checkout-step-title__border;
@checkout-payment-method-title__padding: @checkout-shipping-method__padding;
@checkout-payment-method-title-mobile__padding: 15px;
@checkout-payment-method-content__padding__xl: 22px;
@checkout-billing-address-details__line-height: 27px;
@checkout-billing-address-details__padding: 0 0 0 23px;
@checkout-billing-address-form__max-width: @checkout-shipping-address__max-width;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.action.action-edit-address{
.ox-button-secondary();
padding: 8px 12px;
margin-top: 20px;
}
.checkout-payment-method {
.step-title {
border-bottom: 0;
margin-bottom: 0;
}
.payment-method {
&:first-child {
.payment-method-title {
border-top: 0;
}
}
&._active {
.payment-method-content {
display: block;
}
}
& + .payment-method {
.payment-method-title {
.lib-css(border-top, @checkout-payment-method-title__border);
}
}
}
.payment-method-content {
> .actions-toolbar {
> .primary {
.action {
&.primary {
&:extend(.abs-button-l all);
width: 100%;
margin-bottom: 20px;
}
}
}
}
}
.payment-method-title {
.lib-css(padding, @checkout-payment-method-title__padding 0);
margin: 0;
font-weight: @font-weight__black;
text-transform: uppercase;
font-size: 16px;
.payment-icon {
display: inline-block;
margin-right: @indent__xs;
vertical-align: middle;
}
.action-help {
display: inline-block;
margin-left: @indent__xs;
}
}
.payment-method-content {
display: none;
.fieldset {
&:not(:last-child) {
margin: 0 0 @indent__base;
}
}
}
.payment-group {
& + .payment-group {
.step-title {
margin: @indent__base 0 0;
}
}
}
.field-select-billing,
.billing-address-form {
.lib-css(max-width, @checkout-billing-address-form__max-width);
}
/*
.billing-address-same-as-shipping-block {
margin: 0 0 @indent__s;
}*/
.checkout-billing-address {
margin: 0 0 40px;
.choice{
margin-bottom: 15px;
font-weight: @font-weight__bold;
}
.primary {
.action-update {
margin-right: 0;
}
}
/*.action-cancel {
&:extend(.abs-action-button-as-link all);
}*/
.billing-address-details {
.lib-css(line-height, @checkout-billing-address-details__line-height);
.lib-css(padding, @checkout-billing-address-details__padding);
}
}
.payment-method-note {
& + .checkout-billing-address {
margin-top: @indent__base;
}
}
.field-select-billing {
> .label {
&:extend(.abs-visually-hidden all);
}
}
.payment-method-iframe {
background-color: transparent;
display: none;
width: 100%;
}
.no-payments-block {
margin: @indent__base 0;
}
.payments {
.legend {
&:extend(.abs-visually-hidden all);
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__m) {
.checkout-payment-method {
/*
.step-title {
.lib-css(padding-left, @checkout-payment-method-title-mobile__padding);
.lib-css(padding-right, @checkout-payment-method-title-mobile__padding)
}
.payment-method-title {
.lib-css(padding, @checkout-payment-method-title-mobile__padding)
}
.payment-method-content {
.lib-css(padding, 0 @checkout-payment-method-title-mobile__padding @indent__base);
}*/
.checkout-billing-address {
.action-cancel {
margin-top: @indent__s;
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.checkout-payment-method {
/*.actions-toolbar {
.primary {
float: right;
margin: 0;
}
}*/
.fieldset {
> .field-select-billing {
> .control {
float: none;
width: 100%;
}
}
}
.payment-method-content {
.fieldset {
> .field {
margin: 0 0 @indent__base;
&.type {
.control {
margin-left: 25.8%;
}
&.no-detection {
.control {
margin-left: 0;
}
}
}
}
}
}
}
.checkout-billing-address {
.action-update {
float: right;
}
.actions-toolbar {
.action-cancel {
margin: 6px @indent__base 0 0;
}
}
}
}
@@ -0,0 +1,194 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-progress-bar__font-size: 16px;
@checkout-progress-bar__font-weight: @font-weight__bold;
@checkout-progress-bar__margin: 0;
@checkout-progress-bar__height: 50px;
@checkout-progress-bar-item__background-color: #f5f5f5;
@checkout-progress-bar-item__border-radius: 0;
@checkout-progress-bar-item__color: #000000;
@checkout-progress-bar-item__margin: 50px;
@checkout-progress-bar-item__width: 66.666667%;
@checkout-progress-bar-item__active__background-color: @main-color;
@checkout-progress-bar-item__complete__color: @checkout-progress-bar-item__color;
/*
@checkout-progress-bar-item-element__height: @checkout-progress-bar-item-element__width;
@checkout-progress-bar-item-element__width: 38px;*/
@checkout-progress-bar-item-element-inner__background-color: @page__background-color;
@checkout-progress-bar-item-element-inner__color: @checkout-progress-bar-item__color;
/*@checkout-progress-bar-item-element-inner__height: @checkout-progress-bar-item-element-inner__width;
@checkout-progress-bar-item-element-inner__width: @checkout-progress-bar-item-element__width - (@checkout-progress-bar-item-element-outer-radius__width * 2);*/
@checkout-progress-bar-item-element-inner__active__content: @icon-checkmark;
@checkout-progress-bar-item-element-inner__active__font-size: 28px;
@checkout-progress-bar-item-element-inner__active__line-height: 1;
@checkout-progress-bar-item-element-outer-radius__width: 6px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
//
// Checkout Progress Bar
// ---------------------------------------------
.opc-progress-bar {
&:extend(.abs-reset-list all);
.lib-css(margin, 0 0 @checkout-progress-bar__margin);
counter-reset: i;
font-size: 0;
position: relative;
width: 100%;
/*max-width: @checkout-progress-bar-item__width;*/
}
.opc-progress-bar-item {
.lib-css(margin, 0 0 @checkout-progress-bar-item__margin);
display: inline-block;
position: relative;
text-align: center;
vertical-align: top;
width: 50%;
background:transparent;
height: @checkout-progress-bar__height;
> span {
display: flex;
align-items: center;
word-wrap: break-word;
position: relative;
z-index: 2;
.lib-typography(
@_color: @checkout-progress-bar-item__color,
@_font-family: false,
@_font-size: @checkout-progress-bar__font-size,
@_font-style: false,
@_font-weight: @checkout-progress-bar__font-weight,
@_line-height: 1
);
height: 100%;
opacity: 0.4;
text-align: left;
padding-left: 60px;
.at-headings();
&:before{
content: '2.';
content: counter(i);
counter-increment: i;
position: absolute;
left: 24px;
top: 50%;
transform: translateY(-50%);
}
}
&:before {
content: '';
.lib-css(background, @checkout-progress-bar-item__background-color);
display: block;
width: 100%;
height: 4px;
position: absolute;
left: 0;
bottom: 0;
transform: scaleX(0);
transform-origin: 0;
animation: transform-0-1 0.9s;
animation-delay: 0.5s;
animation-fill-mode: forwards;
animation-timing-function: cubic-bezier(0.57, 0.39, 0, 1);
}
&._active {
&:before {
.lib-css(background, @checkout-progress-bar-item__active__background-color);
}
}
&._active,
&._complete {
cursor: pointer;
> span {
opacity: 1;
&:before{
content: '';
display: inline-block;
overflow: hidden;
background: #000000;
position: absolute;
left: 22px;
top: 50%;
width: 10px;
height: 3px;
margin-top: -1px;
transform: rotate(45deg) scaleX(0);
transform-origin: 0;
animation: checkboxleft 0.2s;
animation-delay: 1.1s;
animation-fill-mode: forwards;
}
&:after{
content: '';
display: inline-block;
overflow: hidden;
background: #000000;
position: absolute;
left: 27px;
top: 50%;
margin-top: 6px;
width: 15px;
height: 3px;
transform: rotate(-45deg) scaleX(0);
transform-origin: 0;
animation: checkboxright 0.2s;
animation-delay: 1.3s;
animation-fill-mode: forwards;
}
}
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.opc-progress-bar{
/*padding-right: 80px;*/
}
}
//
// Small
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.opc-progress-bar-item{
width: 100%;
font-size: 1.4rem;
}
&._active,
&._complete {
> span:before{
left: 20px;
}
}
&._active,
&._complete{
> span:after{
left: 25px;
}
}
}
@@ -0,0 +1,73 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-shipping-policy-action__color: @link__color;
@checkout-shipping-policy-tooltip__width: 420px;
@checkout-shipping-policy-tooltip-mobile__width: 300px;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.checkout-shipping-method {
position: relative;
}
.shipping-policy-block {
&.field-tooltip {
top: 12px;
.field-tooltip-action {
.lib-css(color, @checkout-shipping-policy-action__color);
cursor: pointer;
&:before {
display: none;
}
span {
&:extend(.abs-visually-hidden-reset all);
}
}
.field-tooltip-content {
&:extend(.abs-add-box-sizing all);
&:extend(.abs-checkout-tooltip-content-position-top all);
.lib-css(width, @checkout-shipping-policy-tooltip__width);
top: @indent__l;
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.shipping-policy-block {
&.field-tooltip {
margin-bottom: @indent__base;
position: relative;
right: auto;
top: auto;
.field-tooltip-content {
.lib-css(width, @checkout-shipping-policy-tooltip-mobile__width);
right: auto;
&:before,
&:after {
right: auto;
}
}
}
}
}
@@ -0,0 +1,347 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-shipping-address__max-width: 100%;
@checkout-shipping-address__margin-top: 28px;
@checkout-shipping-item-icon__background-color: @checkout-shipping-item__active__border-color;
@checkout-shipping-item-icon__color: @color-white;
@checkout-shipping-item-icon__content: @icon-checkmark;
@checkout-shipping-item__border: 2px solid #ddd;
@checkout-shipping-item__line-height: 25px;
@checkout-shipping-item__margin: 0 0 @indent__base;
@checkout-shipping-item__padding: @indent__base (@indent__l + 5px) @indent__base @indent__base;
@checkout-shipping-item__transition: .3s border-color;
@checkout-shipping-item__width: 100%/3;
@checkout-shipping-item-tablet__width: 100%/2;
@checkout-shipping-item-mobile__width: 100%;
@checkout-shipping-item__active__border-color: #000000;
@checkout-shipping-item-icon__selected__height: 27px;
@checkout-shipping-item-icon__selected__width: 29px;
@checkout-shipping-item-mobile__padding: 0 0 15px;
@checkout-shipping-item-mobile__margin: @checkout-shipping-item-mobile__padding;
@checkout-shipping-item-mobile__active__padding: 15px (@indent__l + 5px) 15px 18px;
@checkout-shipping-item-before__border-color: @color-gray80;
@checkout-shipping-item-before__height: calc(~'100% - 20px');
@checkout-shipping-method__margin-top: 3px;
@checkout-shipping-method__padding: @indent__base;
@icon-pencil: '\3a';
@icon-check: '\2e';
@icons__athlete-font-name: 'Athlete2';
//
// Common
// _____________________________________________
& when (@media-common = true) {
.opc-wrapper {
//
// Shipping Address
// ---------------------------------------------
.form-login,
.form-shipping-address {
.lib-css(margin-top, @checkout-shipping-address__margin-top);
margin-bottom: @indent__base;
.fieldset {
.note {
font-size: @font-size__base;
margin-top: 7px;
margin-left: -5px;
}
}
}
.form-login .actions-toolbar{
display: flex;
align-items: center;
justify-content: space-between;
flex-flow: wrap;
.secondary a.action{
background: none;
color: #000;
padding: 5px 7px;
font-size: 12px;
margin-bottom: 10px;
margin-top: 10px;
}
}
.shipping-address-items {
font-size: 0;
}
.shipping-address-item {
&:extend(.abs-add-box-sizing all);
.lib-css(border, @checkout-shipping-item__border);
.lib-css(line-height, @checkout-shipping-item__line-height);
.lib-css(margin, @checkout-shipping-item__margin);
.lib-css(padding, @checkout-shipping-item__padding);
.lib-css(transition, @checkout-shipping-item__transition);
.lib-css(width, @checkout-shipping-item-tablet__width);
display: inline-block;
font-size: @font-size__base;
position: relative;
vertical-align: top;
word-wrap: break-word;
min-height: 255px;
&.selected-item {
.lib-css(border-color, @checkout-shipping-item__active__border-color);
&:after {
.lib-css(background, @checkout-shipping-item-icon__background-color);
.lib-css(color, @checkout-shipping-item-icon__color);
.lib-css(content, @icon-check);
.lib-css(font-family, @icons__athlete-font-name);
.lib-css(height, @checkout-shipping-item-icon__selected__height);
.lib-css(width, @checkout-shipping-item-icon__selected__width);
font-size: 12px;
line-height: 21px;
padding-top: 2px;
position: absolute;
right: 0;
text-align: center;
top: 0;
}
.action-select-shipping-item {
&:extend(.abs-no-display-s all);
visibility: hidden;
}
}
}
.field {
&.addresses {
&:extend(.abs-add-clearfix all);
}
}
.action-show-popup {
margin: 0 0 @indent__base;
> span {
&:before {
content: '+';
padding-right: @indent__xs;
}
}
}
.action-select-shipping-item {
float: none;
margin: @indent__base 0 0;
}
.edit-address-link {
display: block;
float: left;
margin: 20px 5px 0 0;
}
}
//
// Shipping Methods
// ---------------------------------------------
.checkout-shipping-method {
.step-title {
margin-bottom: 30px;
}
.no-quotes-block {
margin: @indent__base 0;
}
}
.methods-shipping {
.actions-toolbar {
.action {
&.primary {
&:extend(.abs-button-l all);
margin: 35px 0 0;
/*min-width: 200px;*/
width: 100%;
}
}
}
}
.table-checkout-shipping-method {
thead {
th {
display: none;
}
}
tbody {
td {
.lib-css(margin-top, @checkout-shipping-method__margin-top);
.lib-css(padding-bottom, @checkout-shipping-method__padding);
.lib-css(padding-top, @checkout-shipping-method__padding);
font-weight: @font-weight__bold;
background: #f8f8f8;
&:first-child {
padding-left: 28px;
width: 20px;
max-width: 68px;
}
&.col-error{
width: 100%;
max-width: 100%;
.message.error{
margin: 15px 0;
}
}
}
tr {
&.row{
margin:0;
}
&:first-child {
td {
margin-top: 0;
}
}
}
.row-error {
td {
margin-top: none;
padding-bottom: @indent__s;
padding-top: 0;
}
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
.opc-wrapper {
.form-login {
.lib-css(border-bottom, 1px solid @checkout-shipping-item-before__border-color);
.lib-css(margin, @checkout-shipping-item-mobile__padding);
.lib-css(padding, @checkout-shipping-item-mobile__padding);
}
.shipping-address-item {
/*.lib-css(border-bottom, 1px solid @checkout-shipping-item-before__border-color);*/
.lib-css(margin, @checkout-shipping-item-mobile__margin);
.lib-css(padding, @checkout-shipping-item-mobile__active__padding);
width: 100%;
min-height: inherit;
&.selected-item {
border-bottom-width: 2px;
.edit-address-link {
.lib-css(right, @checkout-shipping-item-icon__selected__width + @indent__s);
}
}
}
.form-login,
.form-shipping-address {
.lib-css(margin-top, @checkout-shipping-address__margin-top);
}
.action-select-shipping-item {
float: none;
width: 100%;
}
.action-show-popup {
width: 100%;
}
.edit-address-link {
.lib-css(width, 30px);
padding:0;
background:none;
.lib-icon-font(
@icon-pencil,
@_icon-font: @icons__athlete-font-name,
@_icon-font-size: 19px,
@_icon-font-line-height: 26px,
@_icon-font-text-hide: true,
@_icon-font-color: @color-gray19,
@_icon-font-color-hover: @color-gray19,
@_icon-font-color-active: @color-gray19
);
margin: 0;
position: absolute;
right: 0;
top: 1px;
}
}
}
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.checkout-shipping-method {
.actions-toolbar {
.action {
&.primary {
margin-top: 50px;
}
}
}
}
.opc-wrapper {
.form-login,
.form-shipping-address {
.lib-css(max-width, @checkout-shipping-address__max-width);
}
}
}
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__l) {
.opc-wrapper {
.shipping-address-item {
width: 48%;
margin-right: 2%;
&:nth-child(3n + 1) {
&:before {
display: none;
}
}
&.selected-item {
&:before {
display: none;
}
+ .shipping-address-item {
&:before {
display: none;
}
}
}
}
}
}
@@ -0,0 +1,82 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-sidebar-shipping-information__padding: 35px 0 0 0;
@checkout-sidebar-shipping-information__line-height: @checkout-billing-address-details__line-height;
@checkout-sidebar-shipping-information-edit-icon__color: #ffffff;
@checkout-sidebar-shipping-information-edit-icon__content: @icon-settings;
@checkout-sidebar-shipping-information-edit-icon__font-size: 28px;
@checkout-sidebar-shipping-information-edit-icon__line-height: 28px;
@checkout-sidebar-shipping-information-edit-icon__top: 0;
@checkout-sidebar-shipping-information-edit-icon__hover__color: @primary__color;
//
// Common
// _____________________________________________
& when (@media-common = true) {
//
// Shipping Information
// ---------------------------------------------
.opc-block-shipping-information {
.lib-css(padding, 0);
.shipping-information{
.lib-css(padding, @checkout-sidebar-shipping-information__padding);
border-top: 1px solid #d1d1d1;
}
.shipping-information-title {
&:extend(.abs-checkout-title all);
margin-bottom: 10px;
margin-top: 0;
position: relative;
.action-edit {
.ox-button-secondary();
/*padding:2px;*/
padding: 8px 12px;
.lib-css(top, @checkout-sidebar-shipping-information-edit-icon__top);
/* .lib-icon-font(
@checkout-sidebar-shipping-information-edit-icon__content,
@_icon-font-size: @checkout-sidebar-shipping-information-edit-icon__font-size,
@_icon-font-line-height: @checkout-sidebar-shipping-information-edit-icon__line-height,
@_icon-font-text-hide: true,
@_icon-font-color: @checkout-sidebar-shipping-information-edit-icon__color,
@_icon-font-color-hover: @checkout-sidebar-shipping-information-edit-icon__hover__color,
@_icon-font-color-active: @checkout-sidebar-shipping-information-edit-icon__color
);*/
margin: 0;
position: absolute;
right: 0;
}
}
.shipping-information-content {
.lib-css(line-height, @checkout-sidebar-shipping-information__line-height);
/*font-size: 16px;
font-weight: @font-weight__heavier;*/
.actions-toolbar {
margin-left: 0;
}
}
.ship-to,
.ship-via {
margin: 0 0 35px;
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__xs) {
.opc-block-shipping-information .shipping-information-title{
font-size: 2.0rem;
}
}
@@ -0,0 +1,27 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-sidebar__margin: @indent__base;
@checkout-sidebar__margin__xl: 46px;
@checkout-sidebar__columns: 4;
//
// Desktop
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.opc-sidebar {
width: 40%;
float: right;
-ms-flex-order: 2;
-webkit-order: 2;
order: 2;
margin-top: 60px;
}
}
@@ -0,0 +1,207 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
//
// Variables
// _____________________________________________
@checkout-tooltip__hover__z-index: @tooltip__z-index;
@checkout-tooltip-icon__width: 24px;
@checkout-tooltip-icon-arrow__font-size: 10px;
@checkout-tooltip-icon-arrow__left: -( @checkout-tooltip-content__padding + @checkout-tooltip-icon-arrow__font-size - @checkout-tooltip-content__border-width - 2);
@checkout-tooltip-icon__color: #000000;
@checkout-tooltip-icon__content: @icon-help;
@checkout-tooltip-icon__font-size: 18px;
@checkout-tooltip-icon__hover__color: #ffffff;
@checkout-tooltip-content__background-color: #202020;
@checkout-tooltip-content__border-color: @color-gray60;
@checkout-tooltip-content__border-width: 0;
@checkout-tooltip-content__font-size: @font-size__base;
@checkout-tooltip-content__padding: 12px;
@checkout-tooltip-content__width: 270px;
@checkout-tooltip-content__active__border-color: @checkout-tooltip-content__background-color;
@checkout-tooltip-content-mobile-popup__width: 200px;
@checkout-tooltip-content-mobile__right: 10px;
@checkout-tooltip-content-mobile__top: 30px + @checkout-tooltip-icon-arrow__font-size;
//
// Common
// _____________________________________________
& when (@media-common = true) {
.field-tooltip .field-tooltip-action {
.lib-icon-text-hide();
}
.field-tooltip {
cursor: pointer;
position: absolute;
right: 0;
top: 6px;
&._active {
.lib-css(z-index, @checkout-tooltip__hover__z-index);
.field-tooltip-content {
display: block;
}
.field-tooltip-action {
&:before {
.lib-css(color, @checkout-tooltip-icon__hover__color);
.lib-css(background-color, #000000);
}
}
}
.label {
.lib-visually-hidden();
}
.field-tooltip-action {
display: inline-block;
text-decoration: none;
&:before{
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
font-size: @checkout-tooltip-icon__font-size;
line-height: 19px;
color: @checkout-tooltip-icon__color;
content: '?';
font-family: @main-font;
display: inline-block;
font-weight: @font-weight__black;
border: 2px solid @checkout-tooltip-icon__color;
overflow: hidden;
width: @checkout-tooltip-icon__width;
height: @checkout-tooltip-icon__width;
speak: none;
text-align: center;
transition: all 0.2s ease;
}
&:hover{
&:before{
.lib-css(background-color, #000000);
.lib-css(color, @checkout-tooltip-icon__hover__color);
}
}
&:focus {
._keyfocus & {
.lib-css(z-index, @checkout-tooltip__hover__z-index);
+ .field-tooltip-content {
display: block;
}
&:before {
.lib-css(color, @checkout-tooltip-icon__hover__color);
.lib-css(background-color, #000000);
}
}
}
}
.field-tooltip-content {
color: #ffffff;
.lib-css(background, @checkout-tooltip-content__background-color);
.lib-css(border, @checkout-tooltip-content__border-width solid @checkout-tooltip-content__border-color);
.lib-css(border-radius, @checkout-tooltip-content__border-width);
.lib-css(font-size, @checkout-tooltip-content__font-size);
.lib-css(padding, @checkout-tooltip-content__padding);
.lib-css(width, @checkout-tooltip-content__width);
display: none;
left: 38px;
position: absolute;
text-transform: none;
top: -9px;
word-wrap: break-word;
z-index: 2;
&:before,
&:after {
.lib-arrow(
@_position: left,
@_size: @checkout-tooltip-icon-arrow__font-size,
@_color: @checkout-tooltip-content__background-color
);
.lib-css(left, @checkout-tooltip-icon-arrow__left);
.lib-css(top, @checkout-tooltip-content__padding);
content: '';
display: block;
position: absolute;
z-index: 3;
}
&:before {
.lib-css(border-right-color, @checkout-tooltip-content__active__border-color);
}
&:after {
.lib-css(border-right-color, @checkout-tooltip-content__background-color);
width: 1px;
z-index: 4;
}
}
}
}
//
// Mobile
// _____________________________________________
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__xs) {
.modal-popup {
.field-tooltip {
.field-tooltip-content {
.lib-css(width, @checkout-tooltip-content-mobile-popup__width);
}
}
}
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break >= @screen__m) {
.field-tooltip {
.field-tooltip-content {
.lib-css(right, -@checkout-tooltip-content-mobile__right);
.lib-css(top, @checkout-tooltip-content-mobile__top);
left: auto;
&:extend(.abs-checkout-tooltip-content-position-top-mobile all);
}
}
}
//
// Tablet
// _____________________________________________
@media only screen and (max-width: @screen__m) {
.field-tooltip .field-tooltip-content {
left: auto;
right: -10px;
top: 40px;
}
.field-tooltip .field-tooltip-content::before,
.field-tooltip .field-tooltip-content::after {
border: 10px solid transparent;
height: 0;
left: auto;
margin-top: -21px;
right: 10px;
top: 0;
width: 0;
}
.field-tooltip .field-tooltip-content::before {
.lib-css(border-bottom-color, @checkout-tooltip-content__border-color);
}
.field-tooltip .field-tooltip-content::after {
.lib-css(border-bottom-color, @checkout-tooltip-content__background-color);
top: 1px;
}
}
@@ -0,0 +1,370 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
define([
'jquery',
'Magento_Customer/js/model/authentication-popup',
'Magento_Customer/js/customer-data',
'Magento_Ui/js/modal/alert',
'Magento_Ui/js/modal/confirm',
'underscore',
'jquery-ui-modules/widget',
'mage/decorate',
'mage/collapsible',
'mage/cookies',
'jquery-ui-modules/effect-fade'
], function ($, authenticationPopup, customerData, alert, confirm, _) {
'use strict';
$.widget('mage.sidebar', {
options: {
isRecursive: true,
minicart: {
maxItemsVisible: 3
}
},
scrollHeight: 0,
shoppingCartUrl: window.checkout.shoppingCartUrl,
/**
* Create sidebar.
* @private
*/
_create: function () {
this._initContent();
},
/**
* Update sidebar block.
*/
update: function () {
$(this.options.targetElement).trigger('contentUpdated');
this._calcHeight();
},
/**
* @private
*/
_initContent: function () {
var self = this,
events = {};
this.element.decorate('list', this.options.isRecursive);
/**
* @param {jQuery.Event} event
*/
events['click ' + this.options.button.close] = function (event) {
event.stopPropagation();
/** OLEGNAX:Old
$(self.options.targetElement).dropdownDialog('close');
*/
/** OLEGNAX:Start **/
$(self.options.targetElement).OXmodalMinicart('close');
/** OLEGNAX:End **/
};
events['click ' + this.options.button.checkout] = $.proxy(function () {
var cart = customerData.get('cart'),
customer = customerData.get('customer'),
cookieOptions = {
samesite: 'lax'
},
element = $(this.options.button.checkout);
if (!customer().firstname && cart().isGuestCheckoutAllowed === false) {
// set URL for redirect on successful login/registration. It's postprocessed on backend.
$.cookie('login_redirect', this.options.url.checkout, cookieOptions);
if (this.options.url.isRedirectRequired) {
element.prop('disabled', true);
location.href = this.options.url.loginUrl;
} else {
authenticationPopup.showModal();
}
return false;
}
element.prop('disabled', true);
location.href = this.options.url.checkout;
}, this);
/**
* @param {jQuery.Event} event
*/
events['click ' + this.options.button.remove] = function (event) {
event.stopPropagation();
confirm({
content: self.options.confirmMessage,
actions: {
/** @inheritdoc */
confirm: function () {
self._removeItem($(event.currentTarget));
},
/** @inheritdoc */
always: function (e) {
e.stopImmediatePropagation();
}
}
});
};
/**
* @param {jQuery.Event} event
*/
events['keyup ' + this.options.item.qty] = function (event) {
self._showItemButton($(event.target));
};
/**
* @param {jQuery.Event} event
*/
events['change ' + this.options.item.qty] = function (event) {
self._showItemButton($(event.target));
};
/**
* @param {jQuery.Event} event
*/
events['click ' + this.options.item.button] = function (event) {
event.stopPropagation();
self._updateItemQty($(event.currentTarget));
};
/**
* @param {jQuery.Event} event
*/
events['focusout ' + this.options.item.qty] = function (event) {
self._validateQty($(event.currentTarget));
};
this._on(this.element, events);
this._calcHeight();
},
/**
* @param {HTMLElement} elem
* @private
*/
_showItemButton: function (elem) {
var itemId = elem.data('cart-item'),
itemQty = elem.data('item-qty');
if (this._isValidQty(itemQty, elem.val())) {
$('#update-cart-item-' + itemId).show('fade', 300);
} else if (elem.val() == 0) { //eslint-disable-line eqeqeq
this._hideItemButton(elem);
} else {
this._hideItemButton(elem);
}
},
/**
* @param {*} origin - origin qty. 'data-item-qty' attribute.
* @param {*} changed - new qty.
* @returns {Boolean}
* @private
*/
_isValidQty: function (origin, changed) {
return origin != changed && //eslint-disable-line eqeqeq
changed.length > 0 &&
changed - 0 == changed && //eslint-disable-line eqeqeq
changed - 0 > 0;
},
/**
* @param {Object} elem
* @private
*/
_validateQty: function (elem) {
var itemQty = elem.data('item-qty');
if (!this._isValidQty(itemQty, elem.val())) {
elem.val(itemQty);
}
},
/**
* @param {HTMLElement} elem
* @private
*/
_hideItemButton: function (elem) {
var itemId = elem.data('cart-item');
$('#update-cart-item-' + itemId).hide('fade', 300);
},
/**
* @param {HTMLElement} elem
* @private
*/
_updateItemQty: function (elem) {
var itemId = elem.data('cart-item');
this._ajax(this.options.url.update, {
'item_id': itemId,
'item_qty': $('#cart-item-' + itemId + '-qty').val()
}, elem, this._updateItemQtyAfter);
},
/**
* Update content after update qty
*
* @param {HTMLElement} elem
*/
_updateItemQtyAfter: function (elem) {
var productData = this._getProductById(Number(elem.data('cart-item')));
if (!_.isUndefined(productData)) {
$(document).trigger('ajax:updateCartItemQty');
if (window.location.href === this.shoppingCartUrl) {
window.location.reload(false);
}
}
this._hideItemButton(elem);
},
/**
* @param {HTMLElement} elem
* @private
*/
_removeItem: function (elem) {
var itemId = elem.data('cart-item');
this._ajax(this.options.url.remove, {
'item_id': itemId
}, elem, this._removeItemAfter);
},
/**
* Update content after item remove
*
* @param {Object} elem
* @private
*/
_removeItemAfter: function (elem) {
var productData = this._getProductById(Number(elem.data('cart-item')));
if (!_.isUndefined(productData)) {
$(document).trigger('ajax:removeFromCart', {
productIds: [productData['product_id']],
productInfo: [
{
'id': productData['product_id']
}
]
});
if (window.location.href.indexOf(this.shoppingCartUrl) === 0) {
window.location.reload();
}
}
},
/**
* Retrieves product data by Id.
*
* @param {Number} productId - product Id
* @returns {Object|undefined}
* @private
*/
_getProductById: function (productId) {
return _.find(customerData.get('cart')().items, function (item) {
return productId === Number(item['item_id']);
});
},
/**
* @param {String} url - ajax url
* @param {Object} data - post data for ajax call
* @param {Object} elem - element that initiated the event
* @param {Function} callback - callback method to execute after AJAX success
*/
_ajax: function (url, data, elem, callback) {
$.extend(data, {
'form_key': $.mage.cookies.get('form_key')
});
$.ajax({
url: url,
data: data,
type: 'post',
dataType: 'json',
context: this,
/** @inheritdoc */
beforeSend: function () {
elem.attr('disabled', 'disabled');
},
/** @inheritdoc */
complete: function () {
elem.attr('disabled', null);
}
})
.done(function (response) {
var msg;
if (response.success) {
callback.call(this, elem, response);
} else {
msg = response['error_message'];
if (msg) {
alert({
content: msg
});
}
}
})
.fail(function (error) {
console.log(JSON.stringify(error));
});
},
/**
* Calculate height of minicart list
*
* @private
*/
_calcHeight: function () {
var self = this,
height = 0,
counter = this.options.minicart.maxItemsVisible,
target = $(this.options.minicart.list),
outerHeight;
/** OLEGNAX:Start **/
var _counter = 0;
/** OLEGNAX:End **/
self.scrollHeight = 0;
target.children().each(function () {
if ($(this).find('.options').length > 0) {
$(this).collapsible();
}
outerHeight = $(this).outerHeight(true);
/** OLEGNAX:Old
if (counter-- > 0) {
/** OLEGNAX:Start **/
_counter++;
if (counter > _counter) {
/** OLEGNAX:End **/
height += outerHeight;
}
self.scrollHeight += outerHeight;
});
target.parent().height(height);
/** OLEGNAX:Start **/
$(this.options.targetElement).trigger('calculatedHeight', [target, counter]);
/** OLEGNAX:End **/
}
});
return $.mage.sidebar;
});
@@ -0,0 +1,203 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
define([
'uiComponent',
'Magento_Customer/js/customer-data',
'jquery',
'ko',
'underscore',
'sidebar',
'mage/translate',
'Athlete2/modal'
], function (Component, customerData, $, ko, _) {
'use strict';
var sidebarInitialized = false,
addToCartCalls = 0,
miniCart;
miniCart = $('div.block.block-minicart[data-role="OXmodalMinicart"]');
/**
* @return {Boolean}
*/
function initSidebar() {
if (miniCart.data('mageSidebar')) {
miniCart.sidebar('update');
}
if (!$('[data-role=product-item]').length) {
return false;
}
miniCart.trigger('contentUpdated');
if (sidebarInitialized) {
return false;
}
sidebarInitialized = true;
miniCart.sidebar({
'targetElement': 'div.block.block-minicart',
'url': {
'checkout': window.checkout.checkoutUrl,
'update': window.checkout.updateItemQtyUrl,
'remove': window.checkout.removeItemUrl,
'loginUrl': window.checkout.customerLoginUrl,
'isRedirectRequired': window.checkout.isRedirectRequired
},
'button': {
'checkout': '#top-cart-btn-checkout',
'remove': '#mini-cart a.action.delete',
'close': '#btn-minicart-close'
},
'showcart': {
'parent': 'span.counter',
'qty': 'span.counter-number',
'label': 'span.counter-label'
},
'minicart': {
'list': '#mini-cart',
'content': '#minicart-content-wrapper',
'qty': 'div.items-total',
'subtotal': 'div.subtotal span.price',
'maxItemsVisible': window.checkout.minicartMaxItemsVisible
},
'item': {
'qty': ':input.cart-item-qty',
'button': ':button.update-cart-item'
},
'confirmMessage': $.mage.__('Are you sure you would like to remove this item from the shopping cart?')
});
}
initSidebar();
return Component.extend({
shoppingCartUrl: window.checkout.shoppingCartUrl,
maxItemsToDisplay: window.checkout.maxItemsToDisplay,
cart: {},
/**
* @override
*/
initialize: function () {
var self = this,
cartData = customerData.get('cart');
this.update(cartData());
cartData.subscribe(function (updatedCart) {
addToCartCalls--;
this.isLoading(addToCartCalls > 0);
sidebarInitialized = false;
this.update(updatedCart);
initSidebar();
}, this);
$('[data-block="minicart"]').on('contentLoading', function () {
addToCartCalls++;
self.isLoading(true);
});
if (
cartData().website_id !== window.checkout.websiteId && cartData().website_id !== undefined ||
cartData().storeId !== window.checkout.storeId && cartData().storeId !== undefined
) {
customerData.reload(['cart'], false);
}
return this._super();
},
isLoading: ko.observable(false),
initSidebar: initSidebar,
/**
* Close mini shopping cart.
*/
closeMinicart: function () {
},
/**
* @param {String} productType
* @return {*|String}
*/
getItemRenderer: function (productType) {
return this.itemRenderer[productType] || 'defaultRenderer';
},
/**
* Update mini shopping cart content.
*
* @param {Object} updatedCart
* @returns void
*/
update: function (updatedCart) {
_.each(updatedCart, function (value, key) {
if (!this.cart.hasOwnProperty(key)) {
this.cart[key] = ko.observable();
}
this.cart[key](value);
if(window.ajaxCartTransport === true) {
$('div.block.block-minicart[data-role="OXmodalMinicart"]').OXmodalMinicart('open', 'added');
}
if(window.ajaxCartTransport === true || window.ajaxCartTransport === false) {
$(document.body).trigger('closeOxQuickview');
}
window.ajaxCartTransport = null;
}, this);
},
/**
* Get cart param by name.
* @param {String} name
* @returns {*}
*/
getCartParamUnsanitizedHtml: function (name) {
if (!_.isUndefined(name)) {
if (!this.cart.hasOwnProperty(name)) {
this.cart[name] = ko.observable();
}
}
var value = this.cart[name]();
if (!value) {
switch (name) {
case 'summary_count':
value = 0;
break;
}
}
return value;
},
/**
* @deprecated please use getCartParamUnsanitizedHtml.
* @param {String} name
* @returns {*}
*/
getCartParam: function (name) {
return this.getCartParamUnsanitizedHtml(name);
},
/**
* Returns array of cart items, limited by 'maxItemsToDisplay' setting
* @returns []
*/
getCartItems: function () {
var items = this.getCartParamUnsanitizedHtml('items') || [];
items = items.slice(parseInt(-this.maxItemsToDisplay, 10));
return items;
},
/**
* Returns count of cart line items
* @returns {Number}
*/
getCartLineItemsCount: function () {
var items = this.getCartParamUnsanitizedHtml('items') || [];
return parseInt(items.length, 10);
}
});
});
@@ -0,0 +1,137 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
define([
'jquery',
'ko',
'uiComponent',
'underscore',
'Magento_Checkout/js/action/select-shipping-address',
'Magento_Checkout/js/model/quote',
'Magento_Checkout/js/model/shipping-address/form-popup-state',
'Magento_Checkout/js/checkout-data',
'Magento_Customer/js/customer-data',
"Magento_Ui/js/modal/modal"
], function ($, ko, Component, _, selectShippingAddressAction, quote, formPopUpState, checkoutData, customerData, modal) {
'use strict';
var countryData = customerData.get('directory-data');
return Component.extend({
defaults: {
template: 'Magento_Checkout/shipping-address/address-renderer/default'
},
/** @inheritdoc */
initObservable: function () {
this._super();
this.isSelected = ko.computed(function () {
var isSelected = false,
shippingAddress = quote.shippingAddress();
if (shippingAddress) {
isSelected = shippingAddress.getKey() == this.address().getKey(); //eslint-disable-line eqeqeq
}
return isSelected;
}, this);
return this;
},
/**
* @param {String} countryId
* @return {String}
*/
getCountryName: function (countryId) {
return countryData()[countryId] != undefined ? countryData()[countryId].name : ''; //eslint-disable-line
},
/**
* Get customer attribute label
*
* @param {*} attribute
* @returns {*}
*/
getCustomAttributeLabel: function (attribute) {
var label;
if (typeof attribute === 'string') {
return attribute;
}
if (attribute.label) {
return attribute.label;
}
if (_.isArray(attribute.value)) {
label = _.map(attribute.value, function (value) {
return this.getCustomAttributeOptionLabel(attribute['attribute_code'], value) || value;
}, this).join(', ');
} else if (typeof attribute.value === 'object') {
label = _.map(Object.values(attribute.value)).join(', ');
} else {
label = this.getCustomAttributeOptionLabel(attribute['attribute_code'], attribute.value);
}
return label || attribute.value;
},
/**
* Get option label for given attribute code and option ID
*
* @param {String} attributeCode
* @param {String} value
* @returns {String|null}
*/
getCustomAttributeOptionLabel: function (attributeCode, value) {
var option,
label,
options = this.source.get('customAttributes') || {};
if (options[attributeCode]) {
option = _.findWhere(options[attributeCode], {
value: value
});
if (option) {
label = option.label;
}
} else if (value.file !== null) {
label = value.file;
}
return label;
},
/** Set selected customer shipping address */
selectAddress: function () {
selectShippingAddressAction(this.address());
checkoutData.setSelectedShippingAddress(this.address().getKey());
// 美国之外不配送提示
var selectedAddress = $('.shipping-address-item.selected-item .shipping-address-country').text();
if(selectedAddress !=='United States'){
$('#shipping-address-tip-modal').modal('openModal');
}
},
/**
* Edit address.
*/
editAddress: function () {
formPopUpState.isVisible(true);
this.showPopup();
},
/**
* Show popup.
*/
showPopup: function () {
$('[data-open-modal="opc-new-shipping-address"]').trigger('click');
}
});
});
@@ -0,0 +1,96 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
define([
'underscore',
'ko',
'mageUtils',
'uiComponent',
'uiLayout',
'Magento_Customer/js/model/address-list'
], function (_, ko, utils, Component, layout, addressList) {
'use strict';
var defaultRendererTemplate = {
parent: '${ $.$data.parentName }',
name: '${ $.$data.name }',
component: 'Magento_Checkout/js/view/shipping-address/address-renderer/default',
provider: 'checkoutProvider'
};
return Component.extend({
defaults: {
template: 'Magento_Checkout/shipping-address/list',
visible: addressList().length > 0,
rendererTemplates: []
},
/** @inheritdoc */
initialize: function () {
this._super()
.initChildren();
addressList.subscribe(function (changes) {
var self = this;
changes.forEach(function (change) {
if (change.status === 'added') {
self.createRendererComponent(change.value, change.index);
}
});
},
this,
'arrayChange'
);
return this;
},
/** @inheritdoc */
initConfig: function () {
this._super();
// the list of child components that are responsible for address rendering
this.rendererComponents = [];
return this;
},
/** @inheritdoc */
initChildren: function () {
_.each(addressList(), this.createRendererComponent, this);
return this;
},
/**
* Create new component that will render given address in the address list
*
* @param {Object} address
* @param {*} index
*/
createRendererComponent: function (address, index) {
var rendererTemplate, templateData, rendererComponent;
if (index in this.rendererComponents) {
this.rendererComponents[index].address(address);
} else {
// rendererTemplates are provided via layout
rendererTemplate = address.getType() != undefined && this.rendererTemplates[address.getType()] != undefined ? //eslint-disable-line
utils.extend({}, defaultRendererTemplate, this.rendererTemplates[address.getType()]) :
defaultRendererTemplate;
templateData = {
parentName: this.name,
name: index
};
rendererComponent = utils.template(rendererTemplate, templateData);
utils.extend(rendererComponent, {
address: ko.observable(address)
});
layout([rendererComponent]);
this.rendererComponents[index] = rendererComponent;
}
}
});
});
@@ -0,0 +1,410 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
define([
'jquery',
'underscore',
'Magento_Ui/js/form/form',
'ko',
'Magento_Customer/js/model/customer',
'Magento_Customer/js/model/address-list',
'Magento_Checkout/js/model/address-converter',
'Magento_Checkout/js/model/quote',
'Magento_Checkout/js/action/create-shipping-address',
'Magento_Checkout/js/action/select-shipping-address',
'Magento_Checkout/js/model/shipping-rates-validator',
'Magento_Checkout/js/model/shipping-address/form-popup-state',
'Magento_Checkout/js/model/shipping-service',
'Magento_Checkout/js/action/select-shipping-method',
'Magento_Checkout/js/model/shipping-rate-registry',
'Magento_Checkout/js/action/set-shipping-information',
'Magento_Checkout/js/model/step-navigator',
'Magento_Ui/js/modal/modal',
'Magento_Checkout/js/model/checkout-data-resolver',
'Magento_Checkout/js/checkout-data',
'uiRegistry',
'mage/translate',
'Magento_Checkout/js/model/shipping-rate-service'
], function (
$,
_,
Component,
ko,
customer,
addressList,
addressConverter,
quote,
createShippingAddress,
selectShippingAddress,
shippingRatesValidator,
formPopUpState,
shippingService,
selectShippingMethodAction,
rateRegistry,
setShippingInformationAction,
stepNavigator,
modal,
checkoutDataResolver,
checkoutData,
registry,
$t
) {
'use strict';
var popUp = null;
return Component.extend({
defaults: {
template: 'Magento_Checkout/shipping',
shippingFormTemplate: 'Magento_Checkout/shipping-address/form',
shippingMethodListTemplate: 'Magento_Checkout/shipping-address/shipping-method-list',
shippingMethodItemTemplate: 'Magento_Checkout/shipping-address/shipping-method-item',
imports: {
countryOptions: '${ $.parentName }.shippingAddress.shipping-address-fieldset.country_id:indexedOptions'
}
},
visible: ko.observable(!quote.isVirtual()),
errorValidationMessage: ko.observable(false),
isCustomerLoggedIn: customer.isLoggedIn,
isFormPopUpVisible: formPopUpState.isVisible,
isFormInline: addressList().length === 0,
isNewAddressAdded: ko.observable(false),
saveInAddressBook: 1,
quoteIsVirtual: quote.isVirtual(),
/**
* @return {exports}
*/
initialize: function () {
var self = this,
hasNewAddress,
fieldsetName = 'checkout.steps.shipping-step.shippingAddress.shipping-address-fieldset';
this._super();
if (!quote.isVirtual()) {
stepNavigator.registerStep(
'shipping',
'',
$t('Shipping'),
this.visible, _.bind(this.navigate, this),
this.sortOrder
);
}
checkoutDataResolver.resolveShippingAddress();
hasNewAddress = addressList.some(function (address) {
return address.getType() == 'new-customer-address'; //eslint-disable-line eqeqeq
});
this.isNewAddressAdded(hasNewAddress);
this.isFormPopUpVisible.subscribe(function (value) {
if (value) {
self.getPopUp().openModal();
}
});
quote.shippingMethod.subscribe(function () {
self.errorValidationMessage(false);
});
registry.async('checkoutProvider')(function (checkoutProvider) {
var shippingAddressData = checkoutData.getShippingAddressFromData();
if (shippingAddressData) {
checkoutProvider.set(
'shippingAddress',
$.extend(true, {}, checkoutProvider.get('shippingAddress'), shippingAddressData)
);
}
checkoutProvider.on('shippingAddress', function (shippingAddrsData, changes) {
var isStreetAddressDeleted, isStreetAddressNotEmpty;
/**
* In last modifying operation street address was deleted.
* @return {Boolean}
*/
isStreetAddressDeleted = function () {
var change;
if (!changes || changes.length === 0) {
return false;
}
change = changes.pop();
if (_.isUndefined(change.value) || _.isUndefined(change.oldValue)) {
return false;
}
if (!change.path.startsWith('shippingAddress.street')) {
return false;
}
return change.value.length === 0 && change.oldValue.length > 0;
};
isStreetAddressNotEmpty = shippingAddrsData.street && !_.isEmpty(shippingAddrsData.street[0]);
if (isStreetAddressNotEmpty || isStreetAddressDeleted()) {
checkoutData.setShippingAddressFromData(shippingAddrsData);
}
});
shippingRatesValidator.initFields(fieldsetName);
});
return this;
},
/**
* Navigator change hash handler.
*
* @param {Object} step - navigation step
*/
navigate: function (step) {
step && step.isVisible(true);
},
/**
* @return {*}
*/
getPopUp: function () {
var self = this,
buttons;
if (!popUp) {
buttons = this.popUpForm.options.buttons;
this.popUpForm.options.buttons = [
{
text: buttons.save.text ? buttons.save.text : $t('Save Address'),
class: buttons.save.class ? buttons.save.class : 'action primary action-save-address',
click: self.saveNewAddress.bind(self)
},
{
text: buttons.cancel.text ? buttons.cancel.text : $t('Cancel'),
class: buttons.cancel.class ? buttons.cancel.class : 'action secondary action-hide-popup',
/** @inheritdoc */
click: this.onClosePopUp.bind(this)
}
];
/** @inheritdoc */
this.popUpForm.options.closed = function () {
self.isFormPopUpVisible(false);
};
this.popUpForm.options.modalCloseBtnHandler = this.onClosePopUp.bind(this);
this.popUpForm.options.keyEventHandlers = {
escapeKey: this.onClosePopUp.bind(this)
};
/** @inheritdoc */
this.popUpForm.options.opened = function () {
// Store temporary address for revert action in case when user click cancel action
self.temporaryAddress = $.extend(true, {}, checkoutData.getShippingAddressFromData());
};
popUp = modal(this.popUpForm.options, $(this.popUpForm.element));
}
return popUp;
},
/**
* Revert address and close modal.
*/
onClosePopUp: function () {
checkoutData.setShippingAddressFromData($.extend(true, {}, this.temporaryAddress));
this.getPopUp().closeModal();
},
/**
* Show address form popup
*/
showFormPopUp: function () {
this.isFormPopUpVisible(true);
},
/**
* Save new shipping address
*/
saveNewAddress: function () {
var addressData,
newShippingAddress;
this.source.set('params.invalid', false);
this.triggerShippingDataValidateEvent();
if (!this.source.get('params.invalid')) {
addressData = this.source.get('shippingAddress');
// if user clicked the checkbox, its value is true or false. Need to convert.
addressData['save_in_address_book'] = this.saveInAddressBook ? 1 : 0;
// New address must be selected as a shipping address
newShippingAddress = createShippingAddress(addressData);
selectShippingAddress(newShippingAddress);
checkoutData.setSelectedShippingAddress(newShippingAddress.getKey());
checkoutData.setNewCustomerShippingAddress($.extend(true, {}, addressData));
this.getPopUp().closeModal();
this.isNewAddressAdded(true);
// 美国之外不配送提示
var selectedAddress = $('.shipping-address-item.selected-item .shipping-address-country').text();
if(selectedAddress !=='United States'){
$('#shipping-address-tip-modal').modal('openModal');
}
}
},
/**
* Shipping Method View
*/
rates: shippingService.getShippingRates(),
isLoading: shippingService.isLoading,
isSelected: ko.computed(function () {
return quote.shippingMethod() ?
quote.shippingMethod()['carrier_code'] + '_' + quote.shippingMethod()['method_code'] :
null;
}),
/**
* @param {Object} shippingMethod
* @return {Boolean}
*/
selectShippingMethod: function (shippingMethod) {
selectShippingMethodAction(shippingMethod);
checkoutData.setSelectedShippingRate(shippingMethod['carrier_code'] + '_' + shippingMethod['method_code']);
return true;
},
/**
* Set shipping information handler
*/
setShippingInformation: function () {
if (this.validateShippingInformation()) {
quote.billingAddress(null);
checkoutDataResolver.resolveBillingAddress();
registry.async('checkoutProvider')(function (checkoutProvider) {
var shippingAddressData = checkoutData.getShippingAddressFromData();
if (shippingAddressData) {
checkoutProvider.set(
'shippingAddress',
$.extend(true, {}, checkoutProvider.get('shippingAddress'), shippingAddressData)
);
}
});
setShippingInformationAction().done(
function () {
stepNavigator.next();
}
);
}
},
/**
* @return {Boolean}
*/
validateShippingInformation: function () {
var shippingAddress,
addressData,
loginFormSelector = 'form[data-role=email-with-possible-login]',
emailValidationResult = customer.isLoggedIn(),
field,
option = _.isObject(this.countryOptions) && this.countryOptions[quote.shippingAddress().countryId],
messageContainer = registry.get('checkout.errors').messageContainer;
if (!quote.shippingMethod()) {
this.errorValidationMessage(
$t('The shipping method is missing. Select the shipping method and try again.')
);
return false;
}
if (!customer.isLoggedIn()) {
$(loginFormSelector).validation();
emailValidationResult = Boolean($(loginFormSelector + ' input[name=username]').valid());
}
if (this.isFormInline) {
this.source.set('params.invalid', false);
this.triggerShippingDataValidateEvent();
if (!quote.shippingMethod()['method_code']) {
this.errorValidationMessage(
$t('The shipping method is missing. Select the shipping method and try again.')
);
}
if (emailValidationResult &&
this.source.get('params.invalid') ||
!quote.shippingMethod()['method_code'] ||
!quote.shippingMethod()['carrier_code']
) {
this.focusInvalid();
return false;
}
shippingAddress = quote.shippingAddress();
addressData = addressConverter.formAddressDataToQuoteAddress(
this.source.get('shippingAddress')
);
//Copy form data to quote shipping address object
for (field in addressData) {
if (addressData.hasOwnProperty(field) && //eslint-disable-line max-depth
shippingAddress.hasOwnProperty(field) &&
typeof addressData[field] != 'function' &&
_.isEqual(shippingAddress[field], addressData[field])
) {
shippingAddress[field] = addressData[field];
} else if (typeof addressData[field] != 'function' &&
!_.isEqual(shippingAddress[field], addressData[field])) {
shippingAddress = addressData;
break;
}
}
if (customer.isLoggedIn()) {
shippingAddress['save_in_address_book'] = 1;
}
selectShippingAddress(shippingAddress);
} else if (customer.isLoggedIn() &&
option &&
option['is_region_required'] &&
!quote.shippingAddress().region
) {
messageContainer.addErrorMessage({
message: $t('Please specify a regionId in shipping address.')
});
return false;
}
if (!emailValidationResult) {
$(loginFormSelector + ' input[name=username]').trigger('focus');
return false;
}
return true;
},
/**
* Trigger Shipping data Validate Event.
*/
triggerShippingDataValidateEvent: function () {
this.source.trigger('shippingAddress.data.validate');
if (this.source.get('shippingAddress.custom_attributes')) {
this.source.trigger('shippingAddress.custom_attributes.data.validate');
}
}
});
});
@@ -0,0 +1,22 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<div class="opc-estimated-wrapper" data-bind="blockLoader: isLoading">
<div class="estimated-block">
<span class="estimated-label" data-bind="i18n: 'Estimated Total'"></span>
<span class="estimated-price" data-bind="text: getValue()"></span>
</div>
<div class="minicart-wrapper">
<button type="button" class="action showcart" data-bind="click: showSidebar" data-toggle="opc-summary">
<svg xmlns="http://www.w3.org/2000/svg" class="minicart-icon-1" width="14" height="16" viewBox="0 0 14 16">
<path d="M11,3V0H3V3H0V16H14V3H11ZM5,2H9V3H5V2Zm7,12H2V5H3V7H5V5H9V7h2V5h1v9Z"></path>
</svg>
<span class="counter qty">
<span class="counter-number" data-bind="text: getQuantity()"></span>
</span>
</button>
</div>
</div>
@@ -0,0 +1,108 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<!--
<div class="block-title">
<strong>
<span class="text" translate="'My Cart'"></span>
<span
class="qty empty"
text="getCartParam('summary_count')"
data-bind="css: { empty: !!getCartParam('summary_count') == false },
attr: { title: $t('Items in Cart') }">
</span>
</strong>
</div>
-->
<div class="block-content">
<if args="getCartParam('summary_count')">
<div class="items-total">
<button type="button"
id="btn-minicart-close"
class="ox-overlay-close-btn"
aria-label="Close"
data-action="close">
<span></span>
</button>
<span class="count" if="maxItemsToDisplay < getCartLineItemsCount()" text="maxItemsToDisplay"></span>
<translate args="'of'" if="maxItemsToDisplay < getCartLineItemsCount()"></translate>
<span class="count" text="getCartParam('summary_count').toLocaleString(window.LOCALE)"></span>
<!-- ko if: (getCartParam('summary_count') > 1) -->
<span translate="'Items in Cart'"></span>
<!--/ko-->
<!-- ko if: (getCartParam('summary_count') <= 1) -->
<span translate="'Item in Cart'"></span>
<!--/ko-->
</div>
</if>
<if args="getCartParam('summary_count')">
<strong class="subtitle" translate="'Recently added item(s)'"></strong>
<div data-action="scroll" class="minicart-items-wrapper">
<ol id="mini-cart" class="minicart-items" data-bind="foreach: { data: getCartItems(), as: 'item' }">
<each args="$parent.getRegion($parent.getItemRenderer(item.product_type))"
render="{name: getTemplate(), data: item, afterRender: function() {$parents[1].initSidebar()}}"
></each>
</ol>
</div>
</if>
<ifnot args="getCartParam('summary_count')">
<div class="empty-cart-wrapper">
<div class="athlete2-icon-cart empty-cart-icon"></div>
<strong class="subtitle empty">Your cart is empty.</strong>
<button type="button"
id="btn-minicart-close"
class="button continue primary"
data-action="close">
<a href="/product-category" style="color: #fff" target="_blank"><span>Shop Now</span></a>
</button>
</div>
<if args="getCartParam('cart_empty_message')">
<p class="minicart empty text" text="getCartParam('cart_empty_message')"></p>
<div class="actions">
<div class="secondary">
<a class="action viewcart" data-bind="attr: {href: shoppingCartUrl}">
<span translate="'View Cart'"></span>
</a>
</div>
</div>
</if>
</ifnot>
<div class="dropdown-bottom-wrapper" if="getCartParam('summary_count')">
<each args="getRegion('subtotalContainer')" render=""></each>
<each args="getRegion('extraInfo')" render=""></each>
<div class="actions">
<div class="primary" if="getCartParam('possible_onepage_checkout')">
<button
id="top-cart-btn-checkout"
type="button"
class="action primary checkout"
data-action="close"
data-bind="
attr: {
title: $t('Checkout')
},
click: closeMinicart()
"
translate="'Checkout'"
></button>
</div>
<div class="secondary">
<a class="action viewcart" data-bind="attr: {href: shoppingCartUrl}">
<span translate="'View Cart'"></span>
</a>
</div>
<div class="extra-actions" data-bind="html: getCartParamUnsanitizedHtml('extra_actions')"></div>
</div>
<div id="minicart-widgets" class="minicart-widgets" if="regionHasElements('promotion')">
<each args="getRegion('promotion')" render=""></each>
</div>
</div>
</div>
<each args="getRegion('sign-in-popup')" render=""></each>
@@ -0,0 +1,121 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<li class="item product product-item" data-role="product-item">
<div class="product">
<!-- ko if: product_has_url -->
<a data-bind="attr: {href: product_url, title: product_name}" tabindex="-1" class="product-item-photo">
<!-- ko foreach: $parent.getRegion('itemImage') -->
<!-- ko template: {name: getTemplate(), data: item.product_image} --><!-- /ko -->
<!-- /ko -->
</a>
<!-- /ko -->
<!-- ko ifnot: product_has_url -->
<span class="product-item-photo">
<!-- ko foreach: $parent.getRegion('itemImage') -->
<!-- ko template: {name: getTemplate(), data: item.product_image} --><!-- /ko -->
<!-- /ko -->
</span>
<!-- /ko -->
<div class="product-item-details">
<strong class="product-item-name">
<!-- ko if: product_has_url -->
<a data-bind="attr: {href: product_url}, html: $parent.getProductNameUnsanitizedHtml(product_name)"></a>
<!-- /ko -->
<!-- ko ifnot: product_has_url -->
<!-- ko text: $parent.getProductNameUnsanitizedHtml(product_name) --><!-- /ko -->
<!-- /ko -->
</strong>
<!-- ko if: options.length -->
<div class="product options" data-mage-init='{"collapsible":{"openedState": "active", "saveState": false}}'>
<span data-role="title" class="toggle"><!-- ko i18n: 'See Details' --><!-- /ko --></span>
<div data-role="content" class="content">
<strong class="subtitle"><!-- ko i18n: 'Options Details' --><!-- /ko --></strong>
<dl class="product options list">
<!-- ko foreach: { data: options, as: 'option' } -->
<dt class="label"><!-- ko text: option.label --><!-- /ko --></dt>
<dd class="values">
<!-- ko if: Array.isArray(option.value) -->
<span data-bind="html: $parents[1].getOptionValueUnsanitizedHtml(option.value.join('<br>'))"></span>
<!-- /ko -->
<!-- ko if: (!Array.isArray(option.value) && ['file', 'html'].includes(option.option_type)) -->
<span data-bind="html: $parents[1].getOptionValueUnsanitizedHtml(option.value)"></span>
<!-- /ko -->
<!-- ko if: (!Array.isArray(option.value) && !['file', 'html'].includes(option.option_type)) -->
<span data-bind="text: option.print_value || option.value"></span>
<!-- /ko -->
</dd>
<!-- /ko -->
</dl>
</div>
</div>
<!-- /ko -->
<div class="product-item-pricing">
<!-- ko if: canApplyMsrp -->
<div class="details-map">
<span class="label" data-bind="i18n: 'Price'"></span>
<span class="value" data-bind="i18n: 'See price before order confirmation.'"></span>
</div>
<!-- /ko -->
<!-- ko ifnot: canApplyMsrp -->
<!-- ko foreach: $parent.getRegion('priceSidebar') -->
<!-- ko template: {name: getTemplate(), data: item.product_price, as: 'price'} --><!-- /ko -->
<!-- /ko -->
<!-- /ko -->
<div class="details-qty qty qty-controls-wrap">
<label class="label" data-bind="i18n: 'Qty', attr: {
for: 'cart-item-'+item_id+'-qty'}"></label>
<a class="icon-minus qty-minus"></a>
<input data-bind="attr: {
id: 'cart-item-'+item_id+'-qty',
'data-cart-item': item_id,
'data-item-qty': qty,
'data-cart-item-id': product_sku
}, value: qty"
type="number"
min="0"
size="4"
class="item-qty cart-item-qty"/>
<a class="icon-plus qty-plus"></a>
<button data-bind="attr: {
id: 'update-cart-item-'+item_id,
'data-cart-item': item_id,
title: $t('Update')
}"
class="update-cart-item"
style="display: none">
<span data-bind="i18n: 'Update'"></span>
</button>
</div>
</div>
<div class="product actions">
<!-- ko if: is_visible_in_site_visibility -->
<div class="primary">
<a data-bind="attr: {href: configure_url, title: $t('Edit item')}" class="action edit">
<span data-bind="i18n: 'Edit'"></span>
</a>
</div>
<!-- /ko -->
<div class="secondary">
<a href="#" data-bind="attr: {'data-cart-item': item_id, title: $t('Remove item')}"
class="action delete">
<span data-bind="i18n: 'Remove'"></span>
</a>
</div>
</div>
</div>
</div>
<div class="message notice" if="$data.message">
<div data-bind="text: $data.message"></div>
</div>
</li>
@@ -0,0 +1,33 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<!-- ko foreach: getRegion('authentication') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
<!-- ko foreach: getRegion('estimation') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
<!-- ko foreach: getRegion('messages') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
<div class="opc-wrapper">
<div class="opc-wrapper-boxed">
<!-- ko foreach: getRegion('progressBar') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
<ol class="opc" id="checkoutSteps">
<!-- ko foreach: getRegion('steps') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
</ol>
</div>
</div>
<!-- ko foreach: getRegion('sidebar') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
@@ -0,0 +1,35 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<div class="shipping-address-item" css="'selected-item' : isSelected() , 'not-selected-item':!isSelected()">
<text args="address().prefix"></text> <text args="address().firstname"></text> <text args="address().middlename"></text>
<text args="address().lastname"></text> <text args="address().suffix"></text><br>
<if args="address().company">
<text args="address().company"></text><br>
</if>
<text args="_.values(_.compact(address().street)).join(', ')"></text><br>
<text args="address().city "></text>, <span text="address().region"></span> <text args="address().postcode"></text><br>
<span class="shipping-address-country"><text args="getCountryName(address().countryId)"></text></span><br>
<a if="address().telephone" attr="'href': 'tel:' + address().telephone" text="address().telephone"></a><br>
<if args="address().vatId">
VAT: <text args="address().vatId"></text><br>
</if>
<each args="data: address().customAttributes, as: 'element'">
<text args="$parent.getCustomAttributeLabel(element)"></text>
<br>
</each>
<button visible="address().isEditable()" type="button"
class="action edit-address-link"
click="editAddress">
<span translate="'Edit'"></span>
</button>
<!-- ko if: (!isSelected()) -->
<button type="button" click="selectAddress" class="action action-select-shipping-item">
<span translate="'Ship Here'"></span>
</button>
<!-- /ko -->
</div>
@@ -0,0 +1,24 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<form class="form form-shipping-address" id="co-shipping-form" data-bind="attr: {'data-hasrequired': $t('* Required Fields')}">
<!-- ko foreach: getRegion('before-fields') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
<div id="shipping-new-address-form" class="fieldset address">
<!-- ko foreach: getRegion('additional-fieldsets') -->
<!-- ko template: getTemplate() --><!-- /ko -->
<!--/ko-->
<!-- ko if: (isCustomerLoggedIn) -->
<div class="field choice" data-bind="visible: !isFormInline">
<input type="checkbox" class="checkbox" id="shipping-save-in-address-book" data-bind="checked: saveInAddressBook" />
<label class="label" for="shipping-save-in-address-book">
<span data-bind="i18n: 'Save in address book'"></span>
</label>
</div>
<!-- /ko -->
</div>
</form>
@@ -0,0 +1,18 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<!-- ko if: (visible)-->
<div class="field addresses">
<div class="control">
<div class="shipping-address-items">
<!-- ko foreach: { data: elems, as: 'element' } -->
<!-- ko template: element.getTemplate() --><!-- /ko -->
<!-- /ko -->
</div>
</div>
</div>
<!-- /ko -->
@@ -0,0 +1,41 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<tr class="row"
click="element.selectShippingMethod">
<td class="col col-method">
<input type="radio"
class="radio"
ifnot="method.error_message"
ko-checked="element.isSelected"
ko-value="method.carrier_code + '_' + method.method_code"
attr="'aria-labelledby': 'label_method_' + method.method_code + '_' + method.carrier_code + ' ' + 'label_carrier_' + method.method_code + '_' + method.carrier_code,
'checked': element.rates().length == 1 || element.isSelected" />
</td>
<!-- ko ifnot: (method.error_message) -->
<td class="col col-price">
<each args="element.getRegion('price')" render=""></each>
</td>
<!-- /ko -->
<td class="col col-method"
attr="'id': 'label_method_' + method.method_code + '_' + method.carrier_code"
text="method.method_title"></td>
<td class="col col-carrier"
attr="'id': 'label_carrier_' + method.method_code + '_' + method.carrier_code"
text="method.carrier_title"></td>
</tr>
<tr class="row row-error"
if="method.error_message">
<td class="col col-error" colspan="4">
<div role="alert" class="message error">
<div text="method.error_message"></div>
</div>
<span class="no-display">
<input type="radio"
attr="'value' : method.method_code, 'id': 's_method_' + method.method_code">
</span>
</td>
</tr>
@@ -0,0 +1,23 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<div id="checkout-shipping-method-load">
<table class="table-checkout-shipping-method">
<thead>
<tr class="row">
<th class="col col-method" translate="'Select Method'"></th>
<th class="col col-price" translate="'Price'"></th>
<th class="col col-method" translate="'Method Title'"></th>
<th class="col col-carrier" translate="'Carrier Title'"></th>
</tr>
</thead>
<tbody>
<!-- ko foreach: { data: rates(), as: 'method'} -->
<!--ko template: { name: element.shippingMethodItemTemplate} --><!-- /ko -->
<!-- /ko -->
</tbody>
</table>
</div>
@@ -0,0 +1,85 @@
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<li id="shipping" class="checkout-shipping-address" data-bind="fadeVisible: visible()">
<div class="step-title" translate="'Shipping Address'" data-role="title"></div>
<div id="checkout-step-shipping"
class="step-content"
data-role="content">
<each if="!quoteIsVirtual" args="getRegion('customer-email')" render="" ></each>
<each args="getRegion('address-list')" render="" ></each>
<each args="getRegion('address-list-additional-addresses')" render="" ></each>
<!-- Address form pop up -->
<if args="!isFormInline">
<div class="new-address-popup">
<button type="button"
class="action action-show-popup"
click="showFormPopUp"
visible="!isNewAddressAdded()">
<span translate="'New Address'"></span>
</button>
</div>
<div id="opc-new-shipping-address"
visible="isFormPopUpVisible()"
render="shippingFormTemplate"></div>
</if>
<each args="getRegion('before-form')" render="" ></each>
<!-- Inline address form -->
<render if="isFormInline" args="shippingFormTemplate"></render>
</div>
</li>
<!--Shipping method template-->
<li id="opc-shipping_method"
class="checkout-shipping-method"
data-bind="fadeVisible: visible(), blockLoader: isLoading"
role="presentation">
<div class="checkout-shipping-method">
<div class="step-title"
translate="'Shipping Methods'"
data-role="title"></div>
<each args="getRegion('before-shipping-method-form')" render="" ></each>
<div id="checkout-step-shipping_method"
class="step-content"
data-role="content"
role="tabpanel"
aria-hidden="false">
<form id="co-shipping-method-form"
class="form methods-shipping"
if="rates().length"
submit="setShippingInformation"
novalidate="novalidate">
<render args="shippingMethodListTemplate"></render>
<div id="onepage-checkout-shipping-method-additional-load">
<each args="getRegion('shippingAdditional')" render="" ></each>
</div>
<div role="alert"
if="errorValidationMessage().length"
class="message notice">
<span text="errorValidationMessage()"></span>
</div>
<div class="actions-toolbar" id="shipping-method-buttons-container">
<div class="primary">
<button data-role="opc-continue" type="submit" class="button action continue primary">
<span translate="'Next'"></span>
</button>
</div>
</div>
</form>
<div class="no-quotes-block"
ifnot="rates().length > 0"
translate="'Sorry, no quotes are available for this order at this time'"></div>
</div>
</div>
</li>