Compare commits
4 Commits
92a8db6e72
...
feature/fa
| Author | SHA1 | Date | |
|---|---|---|---|
| a128906dc0 | |||
| ddec414409 | |||
| 48e776d80d | |||
| abd2cdc145 |
19
falcon/_dev/css/custom.scss
Normal file
19
falcon/_dev/css/custom.scss
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
// NOTE: All bootstrap overrides have been configured under the abstracts/variables/bootstrap folder.
|
||||||
|
|
||||||
|
//Abstracts: Things used throughout the site such as utility classes and generic overrides.
|
||||||
|
//@import "custom/abstracts/base";
|
||||||
|
//@import "custom/abstracts/utilities";
|
||||||
|
|
||||||
|
// Components: parts of the theme itself that are not associated with a module.
|
||||||
|
//@import "custom/components/";
|
||||||
|
|
||||||
|
// Modules: Styling for specific modules.
|
||||||
|
//@import "custom/modules/";
|
||||||
|
|
||||||
|
//Layouts: Parts of a page, such as the header, footer, etc.
|
||||||
|
//@import "custom/layout/header";
|
||||||
|
//@import "custom/layout/footer";
|
||||||
|
|
||||||
|
// Pages
|
||||||
|
//@import "custom/pages/category";
|
||||||
|
//@import "custom/pages/product";
|
||||||
@ -1,2 +1,3 @@
|
|||||||
@import "abstracts/index";
|
@import "abstracts/index";
|
||||||
@import "theme/index";
|
@import "theme/index";
|
||||||
|
@import "custom";
|
||||||
|
|||||||
@ -5,3 +5,4 @@
|
|||||||
@import "layout/index";
|
@import "layout/index";
|
||||||
@import "components/index";
|
@import "components/index";
|
||||||
|
|
||||||
|
@import "custom/custom";
|
||||||
|
|||||||
22
falcon/_dev/css/theme/custom/_custom.scss
Normal file
22
falcon/_dev/css/theme/custom/_custom.scss
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
/* This is the main custom SCSS file for the Falcon theme.
|
||||||
|
|
||||||
|
I am loosely following the 7 in 1 structure for better organization of the styles. Learn more here:
|
||||||
|
https://medium.com/@diyorbekjuraev77/be-a-master-at-creating-the-7-1-sass-pattern-776fdfb5a3b1
|
||||||
|
|
||||||
|
⚠️NOTE: All bootstrap overrides have been configured under themes/falcon/_dev/css/abstracts/variables/bootstrap */
|
||||||
|
|
||||||
|
//Abstracts: Things used throughout the site such as utility classes and generic overrides.
|
||||||
|
//@import "abstracts/mixins";
|
||||||
|
|
||||||
|
// Components: parts of the theme itself that are not associated with a module.
|
||||||
|
//@import "components/buttons";
|
||||||
|
|
||||||
|
// Modules: Styling for specific modules.
|
||||||
|
//@import "modules/";
|
||||||
|
|
||||||
|
//Layouts: Parts of a page, such as the header, footer, etc.
|
||||||
|
//@import "layout/footer";
|
||||||
|
//@import "layout/header";
|
||||||
|
|
||||||
|
// Pages
|
||||||
|
//@import "pages/home";
|
||||||
@ -13,7 +13,6 @@ import "@js/theme/components/quickview";
|
|||||||
import "@js/theme/components/product";
|
import "@js/theme/components/product";
|
||||||
import "@js/theme/components/cart/cart";
|
import "@js/theme/components/cart/cart";
|
||||||
import "@js/theme/components/cart/block-cart";
|
import "@js/theme/components/cart/block-cart";
|
||||||
import "@js/theme/components/product_miniature_form";
|
|
||||||
|
|
||||||
import usePasswordPolicy from "@js/theme/components/usePasswordPolicy";
|
import usePasswordPolicy from "@js/theme/components/usePasswordPolicy";
|
||||||
import prestashop from "prestashop";
|
import prestashop from "prestashop";
|
||||||
@ -80,4 +79,19 @@ $(() => {
|
|||||||
$(".js-select-link").on("change", ({ target }) => {
|
$(".js-select-link").on("change", ({ target }) => {
|
||||||
window.location.href = $(target).val();
|
window.location.href = $(target).val();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Postcode input formatting
|
||||||
|
const $postCodeInput = $("input[name='postcode']");
|
||||||
|
$postCodeInput.on("input", function () {
|
||||||
|
let value = $(this).val();
|
||||||
|
|
||||||
|
// Match 4 digits followed by 2 letters (e.g., 1234AB)
|
||||||
|
const match = value.match(/^(\d{4})([a-zA-Z]{2})$/);
|
||||||
|
|
||||||
|
if (match) {
|
||||||
|
// Add space between numbers and letters
|
||||||
|
const formatted = `${match[1]} ${match[2]}`;
|
||||||
|
$(this).val(formatted);
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@ -1,7 +1,15 @@
|
|||||||
|
{* Defensive: Handles LazyArray objects for category *}
|
||||||
|
{if is_object($category)}
|
||||||
|
{$category = $category|json_encode|json_decode:true}
|
||||||
|
{if isset($category.category)}
|
||||||
|
{$category = $category.category}
|
||||||
|
{/if}
|
||||||
|
{/if}
|
||||||
|
|
||||||
<div id="js-product-list-footer">
|
<div id="js-product-list-footer">
|
||||||
{if $category.additional_description && $listing.pagination.items_shown_from == 1}
|
{if isset($category.additional_description) && $category.additional_description && $listing.pagination.items_shown_from == 1}
|
||||||
<div id="category-description-2" class="cms-content my-3">
|
<div id="category-description-2" class="cms-content my-3">
|
||||||
{$category.additional_description nofilter}
|
{$category.additional_description nofilter}
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
Reference in New Issue
Block a user