feat: change Location hero illustration to photo

makes it more manageable to add new locations by just picking a photo
This commit is contained in:
2024-07-25 18:59:52 +02:00
parent 048c126986
commit d2347cc7b2
5 changed files with 41 additions and 41 deletions

View File

@@ -62,24 +62,26 @@
$previousPage = from.url.pathname
// Enable page loading state if URL changed
if (from.route.id !== to.route.id) {
if (from?.route.id !== to?.route.id) {
$pageLoading = true
}
})
afterNavigate(() => {
afterNavigate(({ from }) => {
// Remove page loading state
setTimeout(() => $pageLoading = false, DELAY.PAGE_LOADING)
// Scroll back to top when new page is ready (excepted certain pages)
if (!$page.url.searchParams.get('country') && !$page.url.pathname.includes('/shop/')) {
if (from?.url?.pathname && (!$page.url.searchParams.get('country') && !$page.url.pathname.includes('/shop/'))) {
setTimeout(scrollToTop, DELAY.PAGE_IN)
}
})
// Define page loading
$: if (browser) {
// Define page loading
document.body.classList.toggle('is-loading', $pageLoading)
// Block scroll on certain conditions
// document.body.classList.toggle('block-scroll', condition)
}
@@ -120,7 +122,7 @@
<Toast
type="global"
id="posters-promo"
text="Upgrade your walls! <strong>10% off</strong> in cart with free shipping on our graphic posters."
text="Upgrade your walls! Our graphic posters are <strong>10% off</strong> in cart with free shipping."
cta={{
label: 'View posters',
url: '/shop',