From 3f51cb5e536a2d68ec81f856e5ee71ce58b40876 Mon Sep 17 00:00:00 2001 From: Alexander Schmidt Date: Sat, 7 Feb 2026 09:04:13 +0100 Subject: [PATCH] fix: remove restricted fields from public listing query, fix service worker offline fallback, style description as card and remove redundant heading --- js/components/pages/page-listing.js | 10 ++++++++-- js/services/directus.js | 2 -- service-worker.js | 2 +- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/js/components/pages/page-listing.js b/js/components/pages/page-listing.js index de581ca..7dc31fd 100644 --- a/js/components/pages/page-listing.js +++ b/js/components/pages/page-listing.js @@ -212,7 +212,6 @@ class PageListing extends HTMLElement {
-

${t('listing.description')}

${this.formatDescription(this.listing.description)}
@@ -746,7 +745,14 @@ style.textContent = /* css */` filter: grayscale(1); } - page-listing .listing-description, + page-listing .listing-description { + background: var(--color-bg-secondary); + border: 1px solid var(--color-border); + border-radius: var(--radius-lg); + padding: var(--space-lg); + margin-bottom: var(--space-xl); + } + page-listing .listing-location-section { margin-bottom: var(--space-xl); } diff --git a/js/services/directus.js b/js/services/directus.js index 89b35e5..cc5bf2f 100644 --- a/js/services/directus.js +++ b/js/services/directus.js @@ -379,9 +379,7 @@ class DirectusService { 'shipping', 'shipping_cost', 'views', - 'payment_status', 'expires_at', - 'monero_address', 'date_created', 'user_created', 'images.directus_files_id.id', diff --git a/service-worker.js b/service-worker.js index 819f565..f716316 100644 --- a/service-worker.js +++ b/service-worker.js @@ -167,7 +167,7 @@ async function staleWhileRevalidate(request) { cache.put(request, response.clone()); } return response; - }).catch(() => cached); + }).catch(() => cached || new Response('Offline', { status: 503 })); return cached || fetchPromise; }