@mohasinac/appkit 2.8.10 → 3.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_internal/client/features/layout/SidebarCollapseToggle.js +1 -5
- package/dist/_internal/server/features/auctions/actions.js +0 -1
- package/dist/_internal/server/features/auctions/og.js +0 -1
- package/dist/_internal/server/features/auctions/service.js +0 -4
- package/dist/_internal/server/features/auth/capabilities.js +0 -1
- package/dist/_internal/server/features/blog/actions.js +0 -2
- package/dist/_internal/server/features/brands/actions.js +0 -2
- package/dist/_internal/server/features/cart/actions.js +0 -3
- package/dist/_internal/server/features/checkout/actions.js +11 -20
- package/dist/_internal/server/features/events/actions.js +0 -3
- package/dist/_internal/server/features/events/og.js +0 -1
- package/dist/_internal/server/features/events/service.js +0 -2
- package/dist/_internal/server/features/grouped/data.js +0 -2
- package/dist/_internal/server/features/orders/actions.js +0 -4
- package/dist/_internal/server/features/pre-orders/actions.js +0 -1
- package/dist/_internal/server/features/pre-orders/og.js +0 -1
- package/dist/_internal/server/features/pre-orders/service.js +0 -1
- package/dist/_internal/server/features/products/actions.js +0 -6
- package/dist/_internal/server/features/products/service.js +0 -1
- package/dist/_internal/server/features/promotions/actions.js +0 -3
- package/dist/_internal/server/features/reviews/actions.js +0 -3
- package/dist/_internal/server/functions/https.js +0 -6
- package/dist/_internal/server/functions/manifest.js +0 -1
- package/dist/_internal/server/jobs/core/cleanupRtdbEvents.js +1 -1
- package/dist/_internal/server/jobs/core/wrapJobHandler.js +0 -1
- package/dist/_internal/shared/listing-types/action-tracker.js +1 -1
- package/dist/_internal/shared/serialization/index.js +0 -4
- package/dist/_internal/shared/styles/themed.js +0 -3
- package/dist/client/api/ApiError.js +1 -4
- package/dist/client/api/surface-error.js +0 -1
- package/dist/client/api/useApiQuery.js +0 -1
- package/dist/configs/next.js +0 -1
- package/dist/configs/tailwind.js +0 -1
- package/dist/contracts/field-ops.js +0 -2
- package/dist/core/EventBus.js +0 -2
- package/dist/core/Logger.js +0 -6
- package/dist/core/Queue.js +0 -2
- package/dist/core/hooks/useSyncManager.js +4 -4
- package/dist/core/mutation-events.js +0 -1
- package/dist/core/newsletter.repository.js +2 -6
- package/dist/errors/api-error.js +0 -1
- package/dist/errors/authentication-error.js +0 -1
- package/dist/errors/authorization-error.js +0 -1
- package/dist/errors/base-error.js +1 -3
- package/dist/errors/database-error.js +0 -1
- package/dist/errors/error-handler.js +1 -5
- package/dist/errors/error-mapping.js +1 -6
- package/dist/errors/normalize.js +0 -4
- package/dist/errors/not-found-error.js +0 -1
- package/dist/errors/razorpay-unreachable.js +0 -1
- package/dist/errors/validation-error.js +0 -1
- package/dist/features/about/components/FAQPageView.js +1 -3
- package/dist/features/about/components/FeesView.js +1 -3
- package/dist/features/about/components/HelpPageView.js +1 -3
- package/dist/features/about/components/PublicProfileView.js +4 -4
- package/dist/features/account/components/AddressBook.js +1 -3
- package/dist/features/account/components/AddressForm.js +0 -1
- package/dist/features/account/components/AddressesIndexListing.js +0 -1
- package/dist/features/account/components/MessagesView.js +1 -3
- package/dist/features/account/components/NotificationBell.js +3 -14
- package/dist/features/account/components/NotificationPreferencesPanel.js +1 -1
- package/dist/features/account/components/UserOffersPanel.js +0 -2
- package/dist/features/account/components/UserSidebar.js +1 -3
- package/dist/features/admin/components/AdminBlogEditorView.js +0 -1
- package/dist/features/admin/components/AdminBundleEditorView.js +0 -1
- package/dist/features/admin/components/AdminBundlesView.js +0 -1
- package/dist/features/admin/components/AdminCarouselEditorView.js +1 -5
- package/dist/features/admin/components/AdminCarouselView.js +1 -4
- package/dist/features/admin/components/AdminCartsView.js +0 -1
- package/dist/features/admin/components/AdminMediaView.js +1 -3
- package/dist/features/admin/components/AdminPayoutsView.js +0 -1
- package/dist/features/admin/components/AdminProductsView.js +1 -3
- package/dist/features/admin/components/AdminSidebar.js +1 -3
- package/dist/features/admin/components/AdminSiteSettingsView.js +1 -5
- package/dist/features/admin/components/AdminSupportTicketDetailView.js +7 -13
- package/dist/features/admin/components/DashboardStats.js +1 -7
- package/dist/features/admin/components/DataListingView.js +1 -5
- package/dist/features/admin/components/DataTable.js +1 -3
- package/dist/features/admin/components/analytics/AdminAnalyticsCharts.js +1 -3
- package/dist/features/admin/components/analytics/AdminStatCard.js +1 -7
- package/dist/features/admin/components/analytics/AdminTopProductsTable.js +1 -3
- package/dist/features/admin/components/sections/adminSectionsBuildParse.js +0 -5
- package/dist/features/admin/hooks/useAdminListingData.js +0 -5
- package/dist/features/admin/hooks/useChat.js +0 -3
- package/dist/features/admin/repository/chat.repository.js +0 -1
- package/dist/features/admin/repository/notification.repository.js +1 -4
- package/dist/features/auctions/components/AuctionBidsTable.js +1 -7
- package/dist/features/auctions/components/AuctionDetailPageView.js +1 -6
- package/dist/features/auctions/components/MarketplaceAuctionCard.js +3 -15
- package/dist/features/auctions/components/PlaceBidFormClient.js +0 -3
- package/dist/features/auctions/repository/bid.repository.js +0 -1
- package/dist/features/auth/components/ForgotPasswordView.js +0 -1
- package/dist/features/auth/components/LoginForm.js +0 -1
- package/dist/features/auth/components/RegisterForm.js +0 -1
- package/dist/features/auth/components/ResetPasswordView.js +0 -1
- package/dist/features/auth/hooks/useAuth.js +0 -1
- package/dist/features/auth/repository/session.repository.js +0 -1
- package/dist/features/auth/repository/token.repository.js +0 -2
- package/dist/features/auth/repository/user.repository.js +0 -1
- package/dist/features/blog/api/[slug]/route.js +1 -1
- package/dist/features/blog/components/BlogFeaturedCard.js +1 -5
- package/dist/features/blog/components/BlogIndexListing.js +0 -1
- package/dist/features/blog/components/BlogListView.js +1 -5
- package/dist/features/blog/components/BlogPostView.js +1 -3
- package/dist/features/cart/components/CartDrawer.js +2 -6
- package/dist/features/cart/repository/cart.repository.js +0 -1
- package/dist/features/categories/api/route.js +0 -1
- package/dist/features/categories/components/BrandDetailPageView.js +1 -13
- package/dist/features/categories/components/BundleDetailView.js +1 -5
- package/dist/features/categories/components/BundleItemsPicker.js +1 -5
- package/dist/features/categories/components/CategoriesIndexListing.js +0 -1
- package/dist/features/categories/components/CategoriesIndexPageView.js +0 -1
- package/dist/features/categories/components/CategoryBundlesListing.js +1 -3
- package/dist/features/categories/components/CategoryDetailPageView.js +1 -16
- package/dist/features/categories/components/CategoryGrid.js +1 -5
- package/dist/features/categories/components/CategorySelectorCreate.js +0 -1
- package/dist/features/categories/components/CategoryTableColumns.js +2 -6
- package/dist/features/categories/components/CategoryTree.js +1 -3
- package/dist/features/categories/components/ConcernCard.js +1 -3
- package/dist/features/collections/components/CollectionCard.js +1 -5
- package/dist/features/contact/email.js +0 -1
- package/dist/features/events/actions/event-actions.js +0 -1
- package/dist/features/events/api/[id]/route.js +0 -1
- package/dist/features/events/components/AdminEventEditorView.js +1 -2
- package/dist/features/events/components/EventCard.js +2 -8
- package/dist/features/events/components/EventRaffleEntryForm.js +1 -3
- package/dist/features/events/components/EventRaffleWinnerView.js +1 -3
- package/dist/features/events/components/EventRafflesSection.js +0 -1
- package/dist/features/events/components/EventsIndexListing.js +0 -1
- package/dist/features/events/hooks/useBulkEvent.js +0 -1
- package/dist/features/events/repository/event-entry.repository.js +0 -1
- package/dist/features/faq/components/ContactCTA.js +1 -3
- package/dist/features/faq/components/FAQAccordion.js +1 -3
- package/dist/features/faq/components/FAQCategorySidebar.js +1 -3
- package/dist/features/faq/components/RelatedFAQs.js +1 -5
- package/dist/features/filters/AsyncFacetSection.js +1 -3
- package/dist/features/filters/FilterFacetSection.js +4 -14
- package/dist/features/forms/Checkbox.js +1 -3
- package/dist/features/forms/Slider.js +1 -3
- package/dist/features/history/hooks/useHistory.js +0 -1
- package/dist/features/history/repository/user-history.repository.js +0 -2
- package/dist/features/homepage/actions/carousel-actions.js +0 -1
- package/dist/features/homepage/actions/homepage-section-actions.js +1 -3
- package/dist/features/homepage/api/carousel/route.js +0 -1
- package/dist/features/homepage/api/route.js +0 -1
- package/dist/features/homepage/components/AdSlot.js +3 -9
- package/dist/features/homepage/components/AdvertisementBanner.js +2 -12
- package/dist/features/homepage/components/BeforeAfterCard.js +1 -5
- package/dist/features/homepage/components/CharacterHotspotForm.js +2 -10
- package/dist/features/homepage/components/CollectionCardsSection.js +1 -3
- package/dist/features/homepage/components/CustomCardsSection.js +1 -5
- package/dist/features/homepage/components/FeaturedResultsSection.js +1 -3
- package/dist/features/homepage/components/GoogleReviewsSection.js +1 -3
- package/dist/features/homepage/components/HeroCarousel.js +5 -26
- package/dist/features/homepage/components/HeroSection.js +2 -6
- package/dist/features/homepage/components/HowItWorksSection.js +2 -8
- package/dist/features/homepage/components/MarketplaceHomepageView.js +0 -8
- package/dist/features/homepage/components/NewsletterBanner.js +2 -10
- package/dist/features/homepage/components/PromoGrid.js +1 -3
- package/dist/features/homepage/components/SecurityHighlightsSection.js +2 -6
- package/dist/features/homepage/components/ShopByCategorySection.js +2 -6
- package/dist/features/homepage/components/SocialPostCard.js +1 -3
- package/dist/features/homepage/components/StatsCounterSection.js +1 -5
- package/dist/features/homepage/components/TrustBadges.js +1 -3
- package/dist/features/homepage/components/TrustFeaturesSection.js +1 -3
- package/dist/features/homepage/components/WelcomeSection.js +2 -16
- package/dist/features/homepage/components/WhatsAppCommunitySection.js +1 -5
- package/dist/features/homepage/lib/social-feed-fetcher.js +0 -8
- package/dist/features/layout/AppLayoutShell.js +1 -3
- package/dist/features/layout/BottomNavbar.js +1 -11
- package/dist/features/media/MediaAudio.js +2 -6
- package/dist/features/media/MediaImage.js +0 -1
- package/dist/features/media/MediaLightbox.js +3 -9
- package/dist/features/media/MediaVideo.js +2 -8
- package/dist/features/media/upload/MediaUploadField.js +1 -3
- package/dist/features/messages/hooks/useConversation.js +0 -2
- package/dist/features/messages/hooks/useConversations.js +0 -1
- package/dist/features/messages/repository/conversations.repository.js +0 -1
- package/dist/features/orders/api/track/[trackingId]/route.js +0 -1
- package/dist/features/orders/components/OrdersList.js +1 -3
- package/dist/features/orders/components/RefundHistoryTable.js +1 -3
- package/dist/features/orders/repository/orders.repository.js +0 -2
- package/dist/features/payments/repository/payout.repository.js +0 -1
- package/dist/features/pre-orders/components/MarketplacePreorderCard.js +2 -6
- package/dist/features/pre-orders/components/PreOrderActionsClient.js +0 -1
- package/dist/features/pre-orders/components/PreOrderBadge.js +1 -3
- package/dist/features/pre-orders/components/PreOrderDetailPageView.js +1 -5
- package/dist/features/products/api/route.js +1 -3
- package/dist/features/products/components/CompareOverlay.js +1 -6
- package/dist/features/products/components/FeatureBadge.js +1 -3
- package/dist/features/products/components/MakeOfferButton.js +0 -2
- package/dist/features/products/components/MarketplaceBundleCard.js +1 -3
- package/dist/features/products/components/MarketplacePrizeDrawCard.js +1 -3
- package/dist/features/products/components/PrizeDrawDetailPageView.js +0 -2
- package/dist/features/products/components/PrizeDrawItemsEditor.js +1 -3
- package/dist/features/products/components/PrizeDrawsSection.js +1 -3
- package/dist/features/products/components/ProductDetailPageView.js +0 -6
- package/dist/features/products/components/ProductFeatureBadges.js +1 -3
- package/dist/features/products/components/ProductFeaturesSelector.js +0 -1
- package/dist/features/products/components/ProductGrid.js +5 -15
- package/dist/features/products/components/ShareButton.js +1 -1
- package/dist/features/products/components/ShowGroupSection.js +3 -7
- package/dist/features/products/components/SublistingCarouselSection.js +2 -4
- package/dist/features/products/repository/product-features.repository.js +0 -1
- package/dist/features/products/repository/products.repository.js +0 -1
- package/dist/features/promotions/components/CouponCard.js +2 -5
- package/dist/features/promotions/repository/coupons.repository.js +0 -1
- package/dist/features/reviews/api/route.js +0 -1
- package/dist/features/reviews/components/ReviewDetailShell.js +3 -13
- package/dist/features/reviews/components/ReviewModal.js +1 -5
- package/dist/features/reviews/components/ReviewSummary.js +2 -6
- package/dist/features/reviews/components/ReviewsIndexListing.js +0 -1
- package/dist/features/reviews/components/ReviewsList.js +1 -7
- package/dist/features/reviews/repository/reviews.repository.js +0 -3
- package/dist/features/scams/actions/scam-actions.js +1 -1
- package/dist/features/scams/components/ScamProfileView.js +1 -3
- package/dist/features/search/components/Search.js +2 -8
- package/dist/features/search/components/SearchFiltersRow.js +1 -3
- package/dist/features/seller/components/PhysicalLocationModal.js +1 -5
- package/dist/features/seller/components/SellerAddressesView.js +1 -6
- package/dist/features/seller/components/SellerAnalyticsAlertsView.js +1 -4
- package/dist/features/seller/components/SellerBidsView.js +1 -3
- package/dist/features/seller/components/SellerBundlesView.js +0 -1
- package/dist/features/seller/components/SellerCouponEditorView.js +1 -3
- package/dist/features/seller/components/SellerFeaturesView.js +0 -1
- package/dist/features/seller/components/SellerGoogleReviewsView.js +1 -1
- package/dist/features/seller/components/SellerLiveView.js +1 -3
- package/dist/features/seller/components/SellerOffersPanel.js +0 -2
- package/dist/features/seller/components/SellerOrdersView.js +1 -6
- package/dist/features/seller/components/SellerPayoutMethodsView.js +0 -1
- package/dist/features/seller/components/SellerPayoutRequestView.js +1 -1
- package/dist/features/seller/components/SellerPayoutSettingsView.js +1 -1
- package/dist/features/seller/components/SellerProductShell.js +2 -4
- package/dist/features/seller/components/SellerProductsCards.js +1 -3
- package/dist/features/seller/components/SellerProductsView.js +1 -7
- package/dist/features/seller/components/SellerReviewsView.js +1 -4
- package/dist/features/seller/components/SellerShippingConfigsView.js +1 -4
- package/dist/features/seller/components/SellerShippingView.js +1 -1
- package/dist/features/seller/components/SellerSidebar.js +4 -12
- package/dist/features/seller/components/SellerStoreCategoriesView.js +0 -2
- package/dist/features/seller/components/SellerTemplatesView.js +0 -1
- package/dist/features/seller/components/analytics/SellerRevenueChart.js +1 -3
- package/dist/features/seller/components/analytics/SellerTopProducts.js +1 -3
- package/dist/features/seller/hooks/useSellerListingData.js +0 -5
- package/dist/features/seller/repository/offer.repository.js +0 -1
- package/dist/features/server-errors/repository/server-errors.repository.js +0 -2
- package/dist/features/shell/FormShell.js +2 -15
- package/dist/features/shell/QuickFormDrawer.js +1 -5
- package/dist/features/site-settings/components/NavPermissionsManager.js +1 -3
- package/dist/features/site-settings/components/ThemeManagerView.js +0 -1
- package/dist/features/stores/api/[storeSlug]/reviews/route.js +0 -1
- package/dist/features/stores/components/StoreGuideHubView.js +1 -1
- package/dist/features/stores/components/StoreHeader.js +1 -7
- package/dist/features/stores/components/StoreReviewsListing.js +0 -1
- package/dist/features/stores/components/StoresIndexListing.js +0 -1
- package/dist/features/stores/repository/store.repository.js +0 -2
- package/dist/features/support/repository/support.repository.js +0 -1
- package/dist/features/wishlist/components/WishlistPage.js +1 -3
- package/dist/features/wishlist/hooks/useWishlistCount.js +1 -1
- package/dist/features/wishlist/repository/user-wishlist.repository.js +0 -2
- package/dist/http/ApiClient.js +4 -12
- package/dist/index.js +0 -1
- package/dist/monitoring/client-logger.js +7 -22
- package/dist/monitoring/error-tracking.js +0 -1
- package/dist/monitoring/performance.js +0 -1
- package/dist/monitoring/server-logger.js +11 -33
- package/dist/next/api/api-response.js +1 -4
- package/dist/next/api/apiHandler.js +1 -5
- package/dist/next/api/errorHandler.js +0 -3
- package/dist/next/api/parseJsonBody.js +0 -1
- package/dist/next/api/routeHandler.js +1 -8
- package/dist/next/cache-middleware.js +1 -3
- package/dist/next/middleware/chain.js +0 -1
- package/dist/next/middleware/pii-scrubber.js +0 -2
- package/dist/providers/auth-firebase/provider.js +0 -1
- package/dist/providers/db-firebase/admin.js +0 -1
- package/dist/providers/db-firebase/base.js +0 -4
- package/dist/providers/db-firebase/base.repository.js +0 -3
- package/dist/providers/db-firebase/field-ops.js +0 -2
- package/dist/providers/db-firebase/helpers.js +0 -4
- package/dist/providers/db-firebase/realtime.js +3 -15
- package/dist/providers/db-firebase/sieve.js +2 -8
- package/dist/providers/payment-razorpay/index.js +0 -3
- package/dist/providers/shipping-shiprocket/index.js +0 -1
- package/dist/providers/storage-firebase/client.js +0 -4
- package/dist/react/contexts/SessionContext.js +0 -1
- package/dist/react/hooks/useCountdown.js +0 -1
- package/dist/security/authorization.js +0 -1
- package/dist/security/pii-encrypt.js +0 -4
- package/dist/security/pii-redact.js +0 -3
- package/dist/seed/manifest.js +1 -6
- package/dist/seed/runner.js +0 -2
- package/dist/styles.css +1 -1
- package/dist/tailwind-utilities.css +1 -1
- package/dist/ui/DataTable.js +2 -6
- package/dist/ui/components/Anchor.js +0 -1
- package/dist/ui/components/AvatarDisplay.js +1 -3
- package/dist/ui/components/BackgroundRenderer.js +2 -6
- package/dist/ui/components/BaseListingCard.js +0 -1
- package/dist/ui/components/Button.js +0 -4
- package/dist/ui/components/Card.js +2 -6
- package/dist/ui/components/Details.js +2 -8
- package/dist/ui/components/Dialog.js +0 -1
- package/dist/ui/components/FallbackShell.js +5 -17
- package/dist/ui/components/Fieldset.js +2 -6
- package/dist/ui/components/HorizontalRule.js +0 -1
- package/dist/ui/components/HotspotMarker.js +1 -3
- package/dist/ui/components/IconBox.js +0 -1
- package/dist/ui/components/Iframe.js +0 -1
- package/dist/ui/components/ImageGallery.js +1 -3
- package/dist/ui/components/ImageLightbox.js +1 -5
- package/dist/ui/components/Kbd.js +0 -1
- package/dist/ui/components/Motion.js +1 -3
- package/dist/ui/components/NavbarChevron.js +0 -1
- package/dist/ui/components/PasswordStrengthIndicator.js +1 -3
- package/dist/ui/components/Progress.js +2 -6
- package/dist/ui/components/Quote.js +1 -4
- package/dist/ui/components/Responsive.js +0 -4
- package/dist/ui/components/RowActionMenu.js +1 -3
- package/dist/ui/components/Scrim.js +0 -1
- package/dist/ui/components/SiteLogo.js +1 -9
- package/dist/ui/components/Skeleton.js +1 -3
- package/dist/ui/components/Slider.js +1 -3
- package/dist/ui/components/StickyToolbar.js +0 -1
- package/dist/ui/components/TabStrip.js +1 -3
- package/dist/ui/components/Toast.js +1 -3
- package/dist/ui/components/Tooltip.js +1 -4
- package/dist/ui/components/UnsavedChangesModal.js +1 -3
- package/dist/ui/rich-text/RichText.js +1 -1
- package/dist/utils/action-response.js +0 -1
- package/dist/utils/date.formatter.js +0 -1
- package/dist/utils/object.helper.js +0 -2
- package/dist/utils/schema-ui.js +1 -3
- package/dist/validation/input.validator.js +0 -1
- package/dist/validation/schemas.js +1 -3
- package/package.json +5 -2
- package/scripts/bundle-css.mjs +47 -0
- package/scripts/copy-assets.mjs +34 -0
- package/scripts/dedupe-peer-deps.mjs +81 -0
|
@@ -19,15 +19,11 @@ function AdsenseAd({ config }) {
|
|
|
19
19
|
// AdSense not loaded yet — no-op
|
|
20
20
|
}
|
|
21
21
|
}, []);
|
|
22
|
-
return (_jsx(Div, { ref: ref, children: _jsx("ins", { className: "adsbygoogle",
|
|
23
|
-
// audit-inline-style-ok: dynamic CSS
|
|
24
|
-
style: { display: "block" }, "data-ad-client": config.adsenseClient ?? "", "data-ad-slot": config.adsenseSlot ?? "", "data-ad-format": config.adsenseFormat ?? "auto", "data-full-width-responsive": "true" }) }));
|
|
22
|
+
return (_jsx(Div, { ref: ref, children: _jsx("ins", { className: "adsbygoogle", style: { display: "block" }, "data-ad-client": config.adsenseClient ?? "", "data-ad-slot": config.adsenseSlot ?? "", "data-ad-format": config.adsenseFormat ?? "auto", "data-full-width-responsive": "true" }) }));
|
|
25
23
|
}
|
|
26
24
|
function ThirdPartyAd({ config }) {
|
|
27
25
|
if (config.thirdPartyUrl) {
|
|
28
|
-
return (_jsx("iframe", { src: config.thirdPartyUrl, width: config.thirdPartyWidth ?? "100%", height: config.thirdPartyHeight ?? "90", scrolling: "no", frameBorder: "0", title: "Advertisement",
|
|
29
|
-
// audit-inline-style-ok: dynamic CSS
|
|
30
|
-
style: { border: 0, overflow: "hidden" }, loading: "lazy" }));
|
|
26
|
+
return (_jsx("iframe", { src: config.thirdPartyUrl, width: config.thirdPartyWidth ?? "100%", height: config.thirdPartyHeight ?? "90", scrolling: "no", frameBorder: "0", title: "Advertisement", style: { border: 0, overflow: "hidden" }, loading: "lazy" }));
|
|
31
27
|
}
|
|
32
28
|
return null;
|
|
33
29
|
}
|
|
@@ -35,9 +31,7 @@ function ManualAdBanner({ ad }) {
|
|
|
35
31
|
const { creative } = ad;
|
|
36
32
|
if (!creative)
|
|
37
33
|
return null;
|
|
38
|
-
return (_jsxs("a", { href: creative.ctaHref || "#", target: creative.ctaHref ? "_blank" : undefined, rel: "noopener noreferrer", className: "flex items-center gap-3 w-full overflow-hidden rounded-lg bg-zinc-100 dark:bg-zinc-800 px-4 py-3 hover:bg-zinc-200 dark:hover:bg-zinc-700 transition-colors no-underline", children: [creative.imageUrl ? (_jsx("img", { src: creative.imageUrl, alt: creative.title || "Advertisement", className: "h-14 w-14 rounded object-cover flex-shrink-0", loading: "lazy" })) : null, _jsxs(Div, { className: "flex-1 min-w-0", children: [creative.title ? (_jsx(Text, { className: "truncate", color: "primary", size: "sm", weight: "semibold", children: creative.title })) : null, creative.body ? (_jsx(Text, { className: "truncate", color: "muted", size: "xs", children: creative.body })) : null] }), creative.ctaLabel ? (
|
|
39
|
-
// audit-variant-ok: CTA pill — bg-primary + py-1.5 (between Span padding map keys)
|
|
40
|
-
_jsx(Span, { color: "inverse", size: "xs", weight: "semibold", className: "flex-shrink-0 bg-primary py-1.5", rounded: "md", padding: "x-sm", children: creative.ctaLabel })) : null] }));
|
|
34
|
+
return (_jsxs("a", { href: creative.ctaHref || "#", target: creative.ctaHref ? "_blank" : undefined, rel: "noopener noreferrer", className: "flex items-center gap-3 w-full overflow-hidden rounded-lg bg-zinc-100 dark:bg-zinc-800 px-4 py-3 hover:bg-zinc-200 dark:hover:bg-zinc-700 transition-colors no-underline", children: [creative.imageUrl ? (_jsx("img", { src: creative.imageUrl, alt: creative.title || "Advertisement", className: "h-14 w-14 rounded object-cover flex-shrink-0", loading: "lazy" })) : null, _jsxs(Div, { className: "flex-1 min-w-0", children: [creative.title ? (_jsx(Text, { className: "truncate", color: "primary", size: "sm", weight: "semibold", children: creative.title })) : null, creative.body ? (_jsx(Text, { className: "truncate", color: "muted", size: "xs", children: creative.body })) : null] }), creative.ctaLabel ? (_jsx(Span, { color: "inverse", size: "xs", weight: "semibold", className: "flex-shrink-0 bg-primary py-1.5", rounded: "md", padding: "x-sm", children: creative.ctaLabel })) : null] }));
|
|
41
35
|
}
|
|
42
36
|
// ---------------------------------------------------------------------------
|
|
43
37
|
// Primary component
|
|
@@ -22,11 +22,7 @@ export function AdvertisementBanner({ title, subtitle, ctaLabel = "Shop now", on
|
|
|
22
22
|
}
|
|
23
23
|
// -- Split layout: when a backgroundImage is provided --
|
|
24
24
|
if (backgroundImage) {
|
|
25
|
-
return (_jsx(Section, { className: `${__P.p8} ${wrapClass} ${className}`, children: _jsx(Div, { className: CLS_CONTAINER, children: _jsx(Div, { className: `relative ${__O.hidden} bg-zinc-900`, rounded: "2xl", shadow: "xl", children: _jsxs(Grid, { className: `${GRID_COLS_2_MD} min-h-[clamp(300px,40vh,420px)]`, children: [_jsxs(Div, { className: `relative ${CARD_ASPECT_BANNER} order-last md:order-first min-h-0 min-h-[clamp(300px,40vh,420px)]`, children: [_jsx(MediaImage, { src: backgroundImage, alt: title, size: "banner", priority: true }), _jsx(Scrim, { direction: "right-to-left", intensity: "medium", className: "hidden md:block absolute inset-y-0 right-0 w-24" })] }), _jsxs(Stack, { justify: "center", className: "relative px-8 md:px-12 md:py-14", padding: "y-2xl", children: [_jsx(Div, { className: "absolute top-0 right-0 w-32 h-32 opacity-10 pointer-events-none bg-[radial-gradient(circle,_white_1px,_transparent_1px)] bg-[length:12px_12px]", "aria-hidden": true }), tagLabel && (
|
|
26
|
-
// audit-variant-ok: translucent-white tag pill over dark ad — no white-overlay surface variant + wide tracking + backdrop-blur
|
|
27
|
-
_jsxs(Span, { layout: "inline-flex", gap: "xs", color: "inverse", size: "xs", weight: "semibold", className: "self-start bg-white/10 /80 tracking-widest mb-5 backdrop-blur-sm", rounded: "full", padding: "pill-md", transform: "uppercase", children: [_jsx(Sparkles, { className: "w-3.5 h-3.5" }), tagLabel] })), _jsx(Heading, { color: "inverse", level: 2, variant: "none", className: "font-extrabold mb-4 leading-tight", mdSize: "4xl", lgSize: "5xl", size: "3xl", children: title }), subtitle && (_jsx(Text, { color: "inverse", variant: "none", className: "/75 mb-8 leading-relaxed", mdSize: "lg", size: "base", children: subtitle })), ctaLabel && onCtaClick && (
|
|
28
|
-
// audit-variant-ok: white CTA pill over dark ad — bg-white + dark-mode preserved zinc tones override Button.variant secondary
|
|
29
|
-
_jsxs(Button, { gap: "md", variant: "secondary", size: "lg", onClick: onCtaClick, className: "self-start bg-white text-zinc-900 hover:bg-zinc-100 dark:bg-zinc-100 dark:text-zinc-900 dark:hover:bg-zinc-200 font-semibold shadow-lg", children: [ctaLabel, _jsx(ArrowRight, { className: "w-4 h-4" })] }))] })] }) }) }) }));
|
|
25
|
+
return (_jsx(Section, { className: `${__P.p8} ${wrapClass} ${className}`, children: _jsx(Div, { className: CLS_CONTAINER, children: _jsx(Div, { className: `relative ${__O.hidden} bg-zinc-900`, rounded: "2xl", shadow: "xl", children: _jsxs(Grid, { className: `${GRID_COLS_2_MD} min-h-[clamp(300px,40vh,420px)]`, children: [_jsxs(Div, { className: `relative ${CARD_ASPECT_BANNER} order-last md:order-first min-h-0 min-h-[clamp(300px,40vh,420px)]`, children: [_jsx(MediaImage, { src: backgroundImage, alt: title, size: "banner", priority: true }), _jsx(Scrim, { direction: "right-to-left", intensity: "medium", className: "hidden md:block absolute inset-y-0 right-0 w-24" })] }), _jsxs(Stack, { justify: "center", className: "relative px-8 md:px-12 md:py-14", padding: "y-2xl", children: [_jsx(Div, { className: "absolute top-0 right-0 w-32 h-32 opacity-10 pointer-events-none bg-[radial-gradient(circle,_white_1px,_transparent_1px)] bg-[length:12px_12px]", "aria-hidden": true }), tagLabel && (_jsxs(Span, { layout: "inline-flex", gap: "xs", color: "inverse", size: "xs", weight: "semibold", className: "self-start bg-white/10 /80 tracking-widest mb-5 backdrop-blur-sm", rounded: "full", padding: "pill-md", transform: "uppercase", children: [_jsx(Sparkles, { className: "w-3.5 h-3.5" }), tagLabel] })), _jsx(Heading, { color: "inverse", level: 2, variant: "none", className: "font-extrabold mb-4 leading-tight", mdSize: "4xl", lgSize: "5xl", size: "3xl", children: title }), subtitle && (_jsx(Text, { color: "inverse", variant: "none", className: "/75 mb-8 leading-relaxed", mdSize: "lg", size: "base", children: subtitle })), ctaLabel && onCtaClick && (_jsxs(Button, { gap: "md", variant: "secondary", size: "lg", onClick: onCtaClick, className: "self-start bg-white text-zinc-900 hover:bg-zinc-100 dark:bg-zinc-100 dark:text-zinc-900 dark:hover:bg-zinc-200 font-semibold shadow-lg", children: [ctaLabel, _jsx(ArrowRight, { className: "w-4 h-4" })] }))] })] }) }) }) }));
|
|
30
26
|
}
|
|
31
27
|
// -- Full-width gradient layout --
|
|
32
28
|
return (_jsx(Section, { className: `${__P.p8} ${wrapClass} ${className}`, children: _jsx(Div, { className: CLS_CONTAINER, children: _jsxs(Row, { align: "center", className: [
|
|
@@ -34,11 +30,5 @@ export function AdvertisementBanner({ title, subtitle, ctaLabel = "Shop now", on
|
|
|
34
30
|
compact
|
|
35
31
|
? "h-[clamp(112px,16vh,160px)]"
|
|
36
32
|
: "min-h-[clamp(240px,34vh,360px)]",
|
|
37
|
-
].join(" "),
|
|
38
|
-
// audit-inline-style-ok: optional inline color
|
|
39
|
-
style: backgroundColor ? { backgroundColor } : undefined, children: [!backgroundColor && (_jsx(Div, { className: CLS_GRADIENT_BG, "aria-hidden": true })), _jsxs(Div, { className: `absolute inset-0 ${__O.hidden}`, "aria-hidden": true, children: [_jsx(Div, { className: "absolute -top-16 -left-16 w-64 h-64 bg-primary/20 blur-3xl animate-pulse", rounded: "full" }), _jsx(Div, { className: "absolute -bottom-16 right-0 w-80 h-80 bg-cobalt/20 blur-3xl animate-pulse", rounded: "full" })] }), compact ? (_jsxs(Row, { justify: "between", className: "relative z-10 w-full", gap: "md", padding: "inlineLg", children: [_jsxs(Span, { layout: "inline-flex", gap: "md", children: [_jsx(Sparkles, { className: "w-4 h-4 text-white/80" }), _jsx(Span, { color: "inverse", size: "sm", weight: "semibold", children: title })] }), ctaLabel && onCtaClick && (_jsxs(Button, { variant: "secondary", size: "sm", onClick: onCtaClick, className: CLS_CTA_BTN_SM, children: [ctaLabel, _jsx(ArrowRight, { className: "w-3.5 h-3.5" })] }))] })) : (
|
|
40
|
-
// audit-variant-ok: gradient banner content — responsive md:py-16 ladder beyond y-3xl base
|
|
41
|
-
_jsxs(Div, { className: "relative z-10 w-full max-w-4xl mx-auto md:py-16 text-center", paddingY: "y-3xl", paddingX: "x-lg", children: [tagLabel && (
|
|
42
|
-
// audit-variant-ok: translucent-white tag pill over gradient ad — no white-overlay surface variant + shadow-sm + backdrop-blur
|
|
43
|
-
_jsxs(Span, { layout: "inline-flex", gap: "xs", color: "inverse", size: "xs", weight: "semibold", className: "bg-white/15 /90 tracking-widest mb-5 backdrop-blur-sm shadow-sm", rounded: "full", padding: "pill-lg", transform: "uppercase", children: [_jsx(Sparkles, { className: "w-3.5 h-3.5" }), tagLabel] })), _jsx(Heading, { color: "inverse", level: 2, variant: "none", className: "lg:text-6xl font-extrabold mb-4 drop-shadow-lg leading-tight", mdSize: "5xl", size: "3xl", children: title }), subtitle && (_jsx(Text, { color: "inverse", variant: "none", className: "mb-10 max-w-2xl mx-auto", mdSize: "xl", size: "base", children: subtitle })), ctaLabel && onCtaClick && (_jsxs(Button, { variant: "secondary", size: "lg", onClick: onCtaClick, className: CLS_CTA_BTN_LG, children: [ctaLabel, _jsx(ArrowRight, { className: "w-4 h-4" })] }))] }))] }) }) }));
|
|
33
|
+
].join(" "), style: backgroundColor ? { backgroundColor } : undefined, children: [!backgroundColor && (_jsx(Div, { className: CLS_GRADIENT_BG, "aria-hidden": true })), _jsxs(Div, { className: `absolute inset-0 ${__O.hidden}`, "aria-hidden": true, children: [_jsx(Div, { className: "absolute -top-16 -left-16 w-64 h-64 bg-primary/20 blur-3xl animate-pulse", rounded: "full" }), _jsx(Div, { className: "absolute -bottom-16 right-0 w-80 h-80 bg-cobalt/20 blur-3xl animate-pulse", rounded: "full" })] }), compact ? (_jsxs(Row, { justify: "between", className: "relative z-10 w-full", gap: "md", padding: "inlineLg", children: [_jsxs(Span, { layout: "inline-flex", gap: "md", children: [_jsx(Sparkles, { className: "w-4 h-4 text-white/80" }), _jsx(Span, { color: "inverse", size: "sm", weight: "semibold", children: title })] }), ctaLabel && onCtaClick && (_jsxs(Button, { variant: "secondary", size: "sm", onClick: onCtaClick, className: CLS_CTA_BTN_SM, children: [ctaLabel, _jsx(ArrowRight, { className: "w-3.5 h-3.5" })] }))] })) : (_jsxs(Div, { className: "relative z-10 w-full max-w-4xl mx-auto md:py-16 text-center", paddingY: "y-3xl", paddingX: "x-lg", children: [tagLabel && (_jsxs(Span, { layout: "inline-flex", gap: "xs", color: "inverse", size: "xs", weight: "semibold", className: "bg-white/15 /90 tracking-widest mb-5 backdrop-blur-sm shadow-sm", rounded: "full", padding: "pill-lg", transform: "uppercase", children: [_jsx(Sparkles, { className: "w-3.5 h-3.5" }), tagLabel] })), _jsx(Heading, { color: "inverse", level: 2, variant: "none", className: "lg:text-6xl font-extrabold mb-4 drop-shadow-lg leading-tight", mdSize: "5xl", size: "3xl", children: title }), subtitle && (_jsx(Text, { color: "inverse", variant: "none", className: "mb-10 max-w-2xl mx-auto", mdSize: "xl", size: "base", children: subtitle })), ctaLabel && onCtaClick && (_jsxs(Button, { variant: "secondary", size: "lg", onClick: onCtaClick, className: CLS_CTA_BTN_LG, children: [ctaLabel, _jsx(ArrowRight, { className: "w-4 h-4" })] }))] }))] }) }) }));
|
|
44
34
|
}
|
|
@@ -55,9 +55,5 @@ export function BeforeAfterCard({ item, beforeLabel = "Before", afterLabel = "Af
|
|
|
55
55
|
setPosition((p) => Math.max(0, p - 2));
|
|
56
56
|
if (e.key === "ArrowRight")
|
|
57
57
|
setPosition((p) => Math.min(100, p + 2));
|
|
58
|
-
}, children: [_jsx(Image, { src: item.afterImage, alt: afterLabel, fill: true, sizes: "(max-width: 640px) 100vw, 50vw", className: "object-cover" }), _jsx(Div, { className: "absolute inset-0 overflow-hidden",
|
|
59
|
-
// audit-inline-style-ok: computed percentage
|
|
60
|
-
style: { width: `${position}%` }, children: _jsx(Image, { src: item.beforeImage, alt: beforeLabel, fill: true, sizes: "(max-width: 640px) 100vw, 50vw", className: "object-cover" }) }), _jsx(Div, { className: "absolute top-0 bottom-0 z-10 w-0.5 bg-card", shadow: "md",
|
|
61
|
-
// audit-inline-style-ok: computed percentage
|
|
62
|
-
style: { left: `${position}%` }, children: _jsx(Row, { className: "absolute top-1/2 left-1/2 h-8 w-8 -translate-x-1/2 -translate-y-1/2 bg-card", align: "center", justify: "center", rounded: "full", shadow: "lg", children: _jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: _jsx("path", { d: "M4 8L1 5M4 8L1 11M4 8H12M12 8L15 5M12 8L15 11", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) }) }) }), _jsx(Span, { surface: "overlay-sm", color: "inverse", size: "xs", weight: "medium", className: "absolute top-3 left-3 z-10", padding: "pill-sm", rounded: "full", children: beforeLabel }), _jsx(Span, { surface: "overlay-sm", color: "inverse", size: "xs", weight: "medium", className: "absolute top-3 right-3 z-10", padding: "pill-sm", rounded: "full", children: afterLabel })] }), _jsx(Div, { className: `${__P.p4}`, children: _jsx(Text, { className: "text-foreground", size: "sm", weight: "medium", children: item.caption }) })] }));
|
|
58
|
+
}, children: [_jsx(Image, { src: item.afterImage, alt: afterLabel, fill: true, sizes: "(max-width: 640px) 100vw, 50vw", className: "object-cover" }), _jsx(Div, { className: "absolute inset-0 overflow-hidden", style: { width: `${position}%` }, children: _jsx(Image, { src: item.beforeImage, alt: beforeLabel, fill: true, sizes: "(max-width: 640px) 100vw, 50vw", className: "object-cover" }) }), _jsx(Div, { className: "absolute top-0 bottom-0 z-10 w-0.5 bg-card", shadow: "md", style: { left: `${position}%` }, children: _jsx(Row, { className: "absolute top-1/2 left-1/2 h-8 w-8 -translate-x-1/2 -translate-y-1/2 bg-card", align: "center", justify: "center", rounded: "full", shadow: "lg", children: _jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: _jsx("path", { d: "M4 8L1 5M4 8L1 11M4 8H12M12 8L15 5M12 8L15 11", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) }) }) }), _jsx(Span, { surface: "overlay-sm", color: "inverse", size: "xs", weight: "medium", className: "absolute top-3 left-3 z-10", padding: "pill-sm", rounded: "full", children: beforeLabel }), _jsx(Span, { surface: "overlay-sm", color: "inverse", size: "xs", weight: "medium", className: "absolute top-3 right-3 z-10", padding: "pill-sm", rounded: "full", children: afterLabel })] }), _jsx(Div, { className: `${__P.p4}`, children: _jsx(Text, { className: "text-foreground", size: "sm", weight: "medium", children: item.caption }) })] }));
|
|
63
59
|
}
|
|
@@ -165,9 +165,7 @@ export function CharacterHotspotForm({ initial, onUploadImage, onSave, onAfterSa
|
|
|
165
165
|
background: pin.accent || "#E8001C",
|
|
166
166
|
border: "2px solid white",
|
|
167
167
|
boxShadow: "0 1px 4px rgba(0,0,0,0.5)",
|
|
168
|
-
}, children: "+" }), pin.name && (
|
|
169
|
-
// audit-variant-ok: absolute-positioned pin tooltip — px-1.5 py-0.5 outside PADDING_MAP scale + arbitrary text-[9px]
|
|
170
|
-
_jsx(Div, { textWeight: "bold", className: "pointer-events-none absolute left-7 top-1/2 -translate-y-1/2 whitespace-nowrap px-1.5 py-0.5 text-[9px] text-white", rounded: "default", style: { background: "#0D0D0D" }, children: pin.name }))] }, pin.id))), draftPos && (_jsxs(Div, { className: "absolute", style: {
|
|
168
|
+
}, children: "+" }), pin.name && (_jsx(Div, { textWeight: "bold", className: "pointer-events-none absolute left-7 top-1/2 -translate-y-1/2 whitespace-nowrap px-1.5 py-0.5 text-[9px] text-white", rounded: "default", style: { background: "#0D0D0D" }, children: pin.name }))] }, pin.id))), draftPos && (_jsxs(Div, { className: "absolute", style: {
|
|
171
169
|
left: `${draftPos.xPct}%`,
|
|
172
170
|
top: `${draftPos.yPct}%`,
|
|
173
171
|
transform: STY_CENTERED,
|
|
@@ -299,13 +297,7 @@ export function CharacterHotspotForm({ initial, onUploadImage, onSave, onAfterSa
|
|
|
299
297
|
background: pin.accent || "#E8001C",
|
|
300
298
|
border: "2px solid white",
|
|
301
299
|
boxShadow: "0 2px 6px rgba(0,0,0,0.55)",
|
|
302
|
-
}, children: "+" }), pin.name && (
|
|
303
|
-
// audit-variant-ok: absolute-positioned pin tooltip — px-1.5 py-0.5 outside PADDING_MAP scale + arbitrary text-[9px]
|
|
304
|
-
_jsx(Div, { textWeight: "bold", className: "pointer-events-none absolute left-8 top-1/2 -translate-y-1/2 whitespace-nowrap px-1.5 py-0.5 text-[9px] text-white", rounded: "default", style: { background: "#0D0D0D" }, children: pin.name }))] }, pin.id)))] }), pins.length > 0 ? (
|
|
305
|
-
// audit-variant-ok: bordered list with divide-y between rows; Ul lacks divide variant
|
|
306
|
-
_jsx(Ul, { className: "divide-y rounded-lg border", style: { borderColor: "var(--border-ink)" }, children: pins.map((pin, i) => (
|
|
307
|
-
// audit-variant-ok: list-row padding px-4 py-3 outside PADDING_MAP scale
|
|
308
|
-
_jsx(Li, { className: "px-4 py-3", children: _jsxs(Row, { gap: "sm", children: [_jsx(Span, { layout: "flex-center", color: "inverse", className: "h-6 w-6 shrink-0", rounded: "full", size: "xs", weight: "bold", style: { background: pin.accent || "#E8001C" }, children: i + 1 }), _jsxs(Div, { className: "min-w-0 flex-1", children: [_jsx(Text, { className: "truncate", size: "sm", weight: "bold", children: pin.name || (_jsx(Span, { className: "italic", style: { color: "var(--color-muted)" }, children: "Unnamed" })) }), _jsxs(Text, { style: { color: "var(--color-muted)" }, size: "xs", children: [pin.universe, " \u00B7 ", pin.xPct.toFixed(0), "%,", " ", pin.yPct.toFixed(0), "%"] })] }), _jsx(Button, { type: "button", onClick: () => deletePin(pin.id), variant: "ghost", className: CLS_DELETE_PIN, title: "Remove pin", children: "\u2715" })] }) }, pin.id))) })) : (_jsx(Div, { textSize: "sm", className: "border-2 border-dashed text-center", rounded: "lg", padding: "xl", style: {
|
|
300
|
+
}, children: "+" }), pin.name && (_jsx(Div, { textWeight: "bold", className: "pointer-events-none absolute left-8 top-1/2 -translate-y-1/2 whitespace-nowrap px-1.5 py-0.5 text-[9px] text-white", rounded: "default", style: { background: "#0D0D0D" }, children: pin.name }))] }, pin.id)))] }), pins.length > 0 ? (_jsx(Ul, { className: "divide-y rounded-lg border", style: { borderColor: "var(--border-ink)" }, children: pins.map((pin, i) => (_jsx(Li, { className: "px-4 py-3", children: _jsxs(Row, { gap: "sm", children: [_jsx(Span, { layout: "flex-center", color: "inverse", className: "h-6 w-6 shrink-0", rounded: "full", size: "xs", weight: "bold", style: { background: pin.accent || "#E8001C" }, children: i + 1 }), _jsxs(Div, { className: "min-w-0 flex-1", children: [_jsx(Text, { className: "truncate", size: "sm", weight: "bold", children: pin.name || (_jsx(Span, { className: "italic", style: { color: "var(--color-muted)" }, children: "Unnamed" })) }), _jsxs(Text, { style: { color: "var(--color-muted)" }, size: "xs", children: [pin.universe, " \u00B7 ", pin.xPct.toFixed(0), "%,", " ", pin.yPct.toFixed(0), "%"] })] }), _jsx(Button, { type: "button", onClick: () => deletePin(pin.id), variant: "ghost", className: CLS_DELETE_PIN, title: "Remove pin", children: "\u2715" })] }) }, pin.id))) })) : (_jsx(Div, { textSize: "sm", className: "border-2 border-dashed text-center", rounded: "lg", padding: "xl", style: {
|
|
309
301
|
borderColor: "var(--border-ink)",
|
|
310
302
|
color: "var(--color-muted)",
|
|
311
303
|
}, children: "No pins yet \u2014 add some using the button below." })), _jsxs(Details, { className: "rounded-lg border p-3", style: { borderColor: "var(--border-ink)" }, children: [_jsx(Summary, { className: "cursor-pointer text-sm font-medium", children: "Image Settings" }), _jsxs(Stack, { className: "mt-3", gap: "3", children: [_jsxs(Label, { layout: "inline-flex", gap: "md", className: "cursor-pointer rounded border-2 border-dashed px-3 py-1.5 transition-colors hover:opacity-80", size: "sm", weight: "medium", style: { borderColor: "var(--border-ink)" }, children: [uploading ? "Uploading…" : "Replace Image", _jsx(Input, { type: "file", accept: "image/*", className: "hidden", onChange: handleImageUpload, disabled: uploading })] }), _jsxs(Stack, { gap: "xs", children: [_jsx(Label, { size: "sm", weight: "bold", children: "Image Alt Text" }), _jsx(Input, { type: "text", value: imageAlt, onChange: (e) => setImageAlt(e.target.value), className: CLS_INPUT, style: {
|
|
@@ -37,7 +37,5 @@ export async function CollectionCardsSection({ config, }) {
|
|
|
37
37
|
if (collections.length === 0) {
|
|
38
38
|
return null;
|
|
39
39
|
}
|
|
40
|
-
return (_jsx(Section, { padding: "y-2xl", children: _jsx(Container, { size: "xl", children: _jsxs(Stack, { gap: "md", children: [_jsxs(Stack, { gap: "xs", children: [_jsx(Heading, { level: 2, size: "2xl", weight: "semibold", color: "primary", children: title }), subtitle ? (_jsx(Text, { size: "sm", color: "muted", children: subtitle })) : null] }), showTabs ? (_jsx(Row, { gap: "sm", wrap: true, children: collections.slice(0, 3).map((entry, idx) => (
|
|
41
|
-
// audit-variant-ok: filter tab Text — pill chip with border-zinc-300 + px-3/py-1 micro padding
|
|
42
|
-
_jsx(Text, { className: "rounded-full border border-zinc-300 px-3 py-1 dark:border-slate-600", color: "muted", size: "xs", weight: "medium", children: entryLabel(entry) }, `${entry.type}-${idx}`))) })) : null, _jsxs(Stack, { align: "center", gap: "sm", className: "border-dashed text-center", border: "strong", paddingY: "y-3xl", paddingX: "x-lg", rounded: "2xl", children: [_jsxs(Text, { size: "sm", color: "muted", children: ["Mixed collection rendering (", collections.length, "/3 collection", collections.length === 1 ? "" : "s", ", up to ", maxItems, " items,", " ", itemsPerRow, " per row) \u2014 data wiring lands with the bundle/raffle work."] }), cta ? (_jsxs(Link, { href: cta.href, className: "text-sm font-medium text-primary hover:underline", children: [cta.label, " \u2192"] })) : null] })] }) }) }));
|
|
40
|
+
return (_jsx(Section, { padding: "y-2xl", children: _jsx(Container, { size: "xl", children: _jsxs(Stack, { gap: "md", children: [_jsxs(Stack, { gap: "xs", children: [_jsx(Heading, { level: 2, size: "2xl", weight: "semibold", color: "primary", children: title }), subtitle ? (_jsx(Text, { size: "sm", color: "muted", children: subtitle })) : null] }), showTabs ? (_jsx(Row, { gap: "sm", wrap: true, children: collections.slice(0, 3).map((entry, idx) => (_jsx(Text, { className: "rounded-full border border-zinc-300 px-3 py-1 dark:border-slate-600", color: "muted", size: "xs", weight: "medium", children: entryLabel(entry) }, `${entry.type}-${idx}`))) })) : null, _jsxs(Stack, { align: "center", gap: "sm", className: "border-dashed text-center", border: "strong", paddingY: "y-3xl", paddingX: "x-lg", rounded: "2xl", children: [_jsxs(Text, { size: "sm", color: "muted", children: ["Mixed collection rendering (", collections.length, "/3 collection", collections.length === 1 ? "" : "s", ", up to ", maxItems, " items,", " ", itemsPerRow, " per row) \u2014 data wiring lands with the bundle/raffle work."] }), cta ? (_jsxs(Link, { href: cta.href, className: "text-sm font-medium text-primary hover:underline", children: [cta.label, " \u2192"] })) : null] })] }) }) }));
|
|
43
41
|
}
|
|
@@ -48,11 +48,7 @@ function CardItem({ card }) {
|
|
|
48
48
|
cardStyle.backgroundColor = card.backgroundColor;
|
|
49
49
|
if (card.textColor)
|
|
50
50
|
cardStyle.color = card.textColor;
|
|
51
|
-
return (_jsxs(Stack, { className: `overflow-hidden ${radiusClass} ${shadowClass} bg-[var(--appkit-color-surface)]`,
|
|
52
|
-
// audit-inline-style-ok: pass-through style prop
|
|
53
|
-
style: cardStyle, children: [card.image && (_jsx(Div, { className: `relative w-full aspect-video ${__O.hidden}`, children: _jsx(MediaImage, { src: card.image, alt: card.imageAlt ?? "", size: "card" }) })), _jsxs(Stack, { className: `${__P.p4} flex-1`, gap: "sm", children: [card.eyebrow && (_jsx(Text, { className: "tracking-widest opacity-70", size: "xs", weight: "semibold", transform: "uppercase", children: card.eyebrow })), card.title && (_jsx(Text, { className: "leading-snug", size: "base", weight: "bold", children: card.title })), card.body && (_jsx(Text, { className: "opacity-80 leading-relaxed flex-1", size: "sm", children: card.body })), card.buttons && card.buttons.length > 0 && (_jsx(Row, { gap: "sm", wrap: true, className: "mt-2", children: card.buttons.map((btn, i) => (_jsx("a", { href: btn.href, target: btn.target ?? "_self", rel: btn.target === "_blank" ? "noopener noreferrer" : undefined, className: VARIANT_CLASS[btn.variant] ?? VARIANT_CLASS.primary, children: btn.label }, i))) })), card.formEmbed && (_jsx("iframe", { src: card.formEmbed, sandbox: "allow-forms allow-scripts", loading: "lazy", className: "w-full mt-3 border-0 rounded-md",
|
|
54
|
-
// audit-inline-style-ok: dynamic CSS
|
|
55
|
-
style: { minHeight: "200px" }, title: "Embedded form" }))] })] }));
|
|
51
|
+
return (_jsxs(Stack, { className: `overflow-hidden ${radiusClass} ${shadowClass} bg-[var(--appkit-color-surface)]`, style: cardStyle, children: [card.image && (_jsx(Div, { className: `relative w-full aspect-video ${__O.hidden}`, children: _jsx(MediaImage, { src: card.image, alt: card.imageAlt ?? "", size: "card" }) })), _jsxs(Stack, { className: `${__P.p4} flex-1`, gap: "sm", children: [card.eyebrow && (_jsx(Text, { className: "tracking-widest opacity-70", size: "xs", weight: "semibold", transform: "uppercase", children: card.eyebrow })), card.title && (_jsx(Text, { className: "leading-snug", size: "base", weight: "bold", children: card.title })), card.body && (_jsx(Text, { className: "opacity-80 leading-relaxed flex-1", size: "sm", children: card.body })), card.buttons && card.buttons.length > 0 && (_jsx(Row, { gap: "sm", wrap: true, className: "mt-2", children: card.buttons.map((btn, i) => (_jsx("a", { href: btn.href, target: btn.target ?? "_self", rel: btn.target === "_blank" ? "noopener noreferrer" : undefined, className: VARIANT_CLASS[btn.variant] ?? VARIANT_CLASS.primary, children: btn.label }, i))) })), card.formEmbed && (_jsx("iframe", { src: card.formEmbed, sandbox: "allow-forms allow-scripts", loading: "lazy", className: "w-full mt-3 border-0 rounded-md", style: { minHeight: "200px" }, title: "Embedded form" }))] })] }));
|
|
56
52
|
}
|
|
57
53
|
// --- Section Header ----------------------------------------------------------
|
|
58
54
|
function SectionHeader({ title }) {
|
|
@@ -7,9 +7,7 @@ export function FeaturedResultsSection({ title, subtitle, pillLabel, ornamentLab
|
|
|
7
7
|
const pillCls = "inline-flex items-center gap-2 rounded-full border border-primary-500/30 bg-primary-500/10 px-5 py-1.5 text-xs font-medium uppercase tracking-[0.2em] text-primary-700 backdrop-blur-sm dark:text-primary-400";
|
|
8
8
|
if (!items.length)
|
|
9
9
|
return null;
|
|
10
|
-
return (
|
|
11
|
-
// audit-variant-ok: section — base paddingY=y-4xl + md:py-20 responsive bump (PADDING_MAP lacks responsive md-up ladder)
|
|
12
|
-
_jsxs(Section, { className: `md:py-20 ${className}`, paddingY: "y-4xl", paddingX: "x-md", children: [_jsxs(Div, { className: "mb-12 text-center", children: [pillLabel && (_jsxs(Span, { className: pillCls, children: [_jsx(Span, { className: "inline-block h-1.5 w-1.5 bg-primary-500", rounded: "full", "aria-hidden": "true" }), pillLabel] })), _jsx(Heading, { level: 2, className: "mt-3 font-display", color: "primary", size: "4xl", children: title }), _jsxs(Row, { align: "center", justify: "center", gap: "sm", color: "faint", className: "mt-3", "aria-hidden": "true", children: [_jsx(Span, { className: "h-px w-6 bg-current" }), _jsx(Span, { size: "xs", children: ornamentLabel }), _jsx(Span, { className: "h-px w-6 bg-current" })] }), subtitle && (_jsx(Text, { className: "mx-auto mt-4 max-w-md", color: "muted", size: "sm", children: subtitle }))] }), _jsx(Div, { className: "mx-auto max-w-7xl", children: _jsx(HorizontalScroller, { items: items, renderItem: (item, i) => (_jsx(Div, { className: "w-full sm:w-auto", children: _jsx(BeforeAfterCard, { item: {
|
|
10
|
+
return (_jsxs(Section, { className: `md:py-20 ${className}`, paddingY: "y-4xl", paddingX: "x-md", children: [_jsxs(Div, { className: "mb-12 text-center", children: [pillLabel && (_jsxs(Span, { className: pillCls, children: [_jsx(Span, { className: "inline-block h-1.5 w-1.5 bg-primary-500", rounded: "full", "aria-hidden": "true" }), pillLabel] })), _jsx(Heading, { level: 2, className: "mt-3 font-display", color: "primary", size: "4xl", children: title }), _jsxs(Row, { align: "center", justify: "center", gap: "sm", color: "faint", className: "mt-3", "aria-hidden": "true", children: [_jsx(Span, { className: "h-px w-6 bg-current" }), _jsx(Span, { size: "xs", children: ornamentLabel }), _jsx(Span, { className: "h-px w-6 bg-current" })] }), subtitle && (_jsx(Text, { className: "mx-auto mt-4 max-w-md", color: "muted", size: "sm", children: subtitle }))] }), _jsx(Div, { className: "mx-auto max-w-7xl", children: _jsx(HorizontalScroller, { items: items, renderItem: (item, i) => (_jsx(Div, { className: "w-full sm:w-auto", children: _jsx(BeforeAfterCard, { item: {
|
|
13
11
|
id: item.id ?? `result-${i}`,
|
|
14
12
|
beforeImage: item.beforeImage,
|
|
15
13
|
afterImage: item.afterImage,
|
|
@@ -10,9 +10,7 @@ const CLS_STAR_OFF = "text-zinc-300 dark:text-zinc-600";
|
|
|
10
10
|
const CLS_GMAPS_LINK = "shrink-0 text-sm font-medium text-blue-600 dark:text-blue-400 hover:underline";
|
|
11
11
|
// --- Star Rating -------------------------------------------------------------
|
|
12
12
|
function StarRating({ rating }) {
|
|
13
|
-
return (
|
|
14
|
-
// audit-variant-ok: star rating Row — gap-0.5 between stars; Row.gap lacks 0.5 key
|
|
15
|
-
_jsx(Row, { className: "gap-0.5", align: "center", "aria-label": `${rating} out of 5 stars`, children: [1, 2, 3, 4, 5].map((star) => (_jsx("svg", { className: `w-4 h-4 ${star <= rating ? CLS_STAR_ON : CLS_STAR_OFF}`, viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": "true", children: _jsx("path", { d: "M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z" }) }, star))) }));
|
|
13
|
+
return (_jsx(Row, { className: "gap-0.5", align: "center", "aria-label": `${rating} out of 5 stars`, children: [1, 2, 3, 4, 5].map((star) => (_jsx("svg", { className: `w-4 h-4 ${star <= rating ? CLS_STAR_ON : CLS_STAR_OFF}`, viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": "true", children: _jsx("path", { d: "M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z" }) }, star))) }));
|
|
16
14
|
}
|
|
17
15
|
// --- Google Logo Badge -------------------------------------------------------
|
|
18
16
|
function GoogleBadge() {
|
|
@@ -70,7 +70,6 @@ function SlideBackground({ bg, legacy, mobileLegacy, isMobile, priority, }) {
|
|
|
70
70
|
const mobileUrl = effectiveBg?.mobileUrl ?? (isMobile && mobileLegacy ? mobileLegacy.url : undefined);
|
|
71
71
|
const src = mobileUrl ?? effectiveBg?.url ?? "";
|
|
72
72
|
if (!effectiveBg) {
|
|
73
|
-
// audit-variant-ok: slide placeholder — bg-zinc-900 over POSITION_FILL; brand placeholder when no slide image
|
|
74
73
|
return _jsx(Div, { className: `${POSITION_FILL} bg-zinc-900` });
|
|
75
74
|
}
|
|
76
75
|
if (effectiveBg.type === "color") {
|
|
@@ -116,20 +115,12 @@ function CarouselCardRenderer({ card, isMobile, push, }) {
|
|
|
116
115
|
gridRow: String(gridPos.gridRow),
|
|
117
116
|
gridColumn: String(gridPos.gridColumn),
|
|
118
117
|
minHeight: isMobile ? 100 : 140,
|
|
119
|
-
}, children: [_jsx(CardBackground, { bg: card.background }), !card.isButtonOnly && (_jsxs(_Fragment, { children: [_jsx(Scrim, { direction: "bottom-up", intensity: "strong", className: POSITION_FILL }), _jsxs(Stack, { justify: "end", className: `${POSITION_FILL} md:p-6 ${textAlignClass}`, padding: "xs", children: [card.content?.eyebrow && (_jsx(Text, { color: "inverse", shadow: "sm", className: "text-[10px] !/70 mb-0.5 tracking-wider", mdSize: "xs", transform: "uppercase", children: card.content.eyebrow })), card.content?.subtitle && (_jsx(Text, { color: "inverse", shadow: "sm", className: "hidden md:block !/90 mb-0.5 md:mb-2", mdSize: "sm", size: "xs", children: card.content.subtitle })), card.content?.title && (
|
|
120
|
-
// audit-variant-ok: card title — arbitrary text-[11px] base + md:text-2xl lg:text-3xl ladder + drop-shadow-md
|
|
121
|
-
_jsx(Heading, { level: 2, className: `text-[11px] md:text-2xl lg:text-3xl mb-0.5 md:mb-3 drop-shadow-md`, truncate: 2, weight: "bold", style: { color: card.content.textColor ?? "#ffffff" }, children: card.content.title })), card.content?.description && (
|
|
122
|
-
// audit-variant-ok: card description — arbitrary text-[10px] base + md:text-sm responsive bump
|
|
123
|
-
_jsx(Text, { color: "inverse", shadow: "sm", className: `text-[10px] md:text-sm !/80 mb-1 md:mb-4`, truncate: true, children: card.content.description })), (card.buttons?.length ?? 0) > 0 && (
|
|
124
|
-
// audit-variant-ok: button row — md:gap-2 responsive gap bump (Row.gap is single-axis)
|
|
125
|
-
_jsx(Row, { wrap: true, gap: "xs", className: "md:gap-2", children: (card.buttons ?? []).map((btn, i) => {
|
|
118
|
+
}, children: [_jsx(CardBackground, { bg: card.background }), !card.isButtonOnly && (_jsxs(_Fragment, { children: [_jsx(Scrim, { direction: "bottom-up", intensity: "strong", className: POSITION_FILL }), _jsxs(Stack, { justify: "end", className: `${POSITION_FILL} md:p-6 ${textAlignClass}`, padding: "xs", children: [card.content?.eyebrow && (_jsx(Text, { color: "inverse", shadow: "sm", className: "text-[10px] !/70 mb-0.5 tracking-wider", mdSize: "xs", transform: "uppercase", children: card.content.eyebrow })), card.content?.subtitle && (_jsx(Text, { color: "inverse", shadow: "sm", className: "hidden md:block !/90 mb-0.5 md:mb-2", mdSize: "sm", size: "xs", children: card.content.subtitle })), card.content?.title && (_jsx(Heading, { level: 2, className: `text-[11px] md:text-2xl lg:text-3xl mb-0.5 md:mb-3 drop-shadow-md`, truncate: 2, weight: "bold", style: { color: card.content.textColor ?? "#ffffff" }, children: card.content.title })), card.content?.description && (_jsx(Text, { color: "inverse", shadow: "sm", className: `text-[10px] md:text-sm !/80 mb-1 md:mb-4`, truncate: true, children: card.content.description })), (card.buttons?.length ?? 0) > 0 && (_jsx(Row, { wrap: true, gap: "xs", className: "md:gap-2", children: (card.buttons ?? []).map((btn, i) => {
|
|
126
119
|
const variant = btn.variant === "link" || btn.variant === "ghost"
|
|
127
120
|
? "ghost"
|
|
128
121
|
: btn.variant;
|
|
129
122
|
return (_jsx(Button, { variant: variant, size: "sm", onClick: makeButtonClickHandler(btn.href, btn.openInNewTab, push), children: btn.text }, btn.id ?? i));
|
|
130
|
-
}) }))] })] })), card.isButtonOnly && card.buttons?.[0] && (
|
|
131
|
-
// audit-variant-ok: button-only card overlay — POSITION_FILL + FLEX_CENTER + hover black/20 overlay
|
|
132
|
-
_jsx(Button, { variant: "ghost", className: `${POSITION_FILL} ${FLEX_CENTER} font-semibold text-white hover:bg-black/20 transition-colors rounded-none p-0`, onClick: makeButtonClickHandler(card.buttons[0].href, card.buttons[0].openInNewTab, push), children: _jsx(Span, { size: "lg", mdSize: "2xl", children: card.buttons[0].text }) }))] }));
|
|
123
|
+
}) }))] })] })), card.isButtonOnly && card.buttons?.[0] && (_jsx(Button, { variant: "ghost", className: `${POSITION_FILL} ${FLEX_CENTER} font-semibold text-white hover:bg-black/20 transition-colors rounded-none p-0`, onClick: makeButtonClickHandler(card.buttons[0].href, card.buttons[0].openInNewTab, push), children: _jsx(Span, { size: "lg", mdSize: "2xl", children: card.buttons[0].text }) }))] }));
|
|
133
124
|
}
|
|
134
125
|
export function HeroCarousel({ initialSlides, push } = {}) {
|
|
135
126
|
const [currentSlide, setCurrentSlide] = useState(0);
|
|
@@ -188,22 +179,12 @@ export function HeroCarousel({ initialSlides, push } = {}) {
|
|
|
188
179
|
return (_jsx(Div, { className: `relative w-full ${heightClass} ${HERO_PLACEHOLDER_BG} animate-pulse`, children: _jsx(Div, { className: `${POSITION_FILL} ${FLEX_CENTER}`, children: _jsx(Text, { variant: "secondary", children: "Loading..." }) }) }));
|
|
189
180
|
}
|
|
190
181
|
if (!slides || slides.length === 0) {
|
|
191
|
-
return (
|
|
192
|
-
// audit-variant-ok: empty-state hero — min-h responsive + gradient bg + FLEX_CENTER + flex-col
|
|
193
|
-
_jsxs(Div, { gap: "4", className: `relative w-full min-h-[260px] md:min-h-[60vh] bg-[image:var(--appkit-gradient-section-cool)] ${FLEX_CENTER} flex-col`, children: [_jsx(Heading, { level: 2, className: "text-primary", size: "2xl", weight: "bold", children: "Coming Soon" }), _jsx(Text, { variant: "secondary", className: "max-w-md px-4", align: "center", children: "Amazing deals are on their way. Stay tuned!" })] }));
|
|
182
|
+
return (_jsxs(Div, { gap: "4", className: `relative w-full min-h-[260px] md:min-h-[60vh] bg-[image:var(--appkit-gradient-section-cool)] ${FLEX_CENTER} flex-col`, children: [_jsx(Heading, { level: 2, className: "text-primary", size: "2xl", weight: "bold", children: "Coming Soon" }), _jsx(Text, { variant: "secondary", className: "max-w-md px-4", align: "center", children: "Amazing deals are on their way. Stay tuned!" })] }));
|
|
194
183
|
}
|
|
195
184
|
return (_jsxs(Section, { ref: sectionRef, className: `relative w-full ${heightClass} overflow-hidden`, "aria-roledescription": "carousel", "aria-label": "Hero carousel", onKeyDown: handleKeyDown, onMouseEnter: () => setIsPaused(true), onMouseLeave: () => setIsPaused(false), onFocus: () => setIsPaused(true), onBlur: () => setIsPaused(false), tabIndex: 0, children: [_jsx(Div, { "aria-live": "polite", "aria-atomic": "true", className: "sr-only", children: `Slide ${currentSlide + 1} of ${slides.length}` }), _jsx(Div, { className: POSITION_FILL, children: _jsx(Div, { layout: "flex", ref: slidesRef, onScroll: handleSlidesScroll, className: "h-full overflow-x-auto scroll-smooth snap-x snap-mandatory [scrollbar-width:none] [&::-webkit-scrollbar]:hidden", style: { gap: 0 }, children: slides.map((slide, slideIndex) => {
|
|
196
185
|
const slideHeightClass = getSlideHeightClass(slide.settings?.height);
|
|
197
186
|
const hasCards = slide.cards && slide.cards.length > 0;
|
|
198
|
-
return (
|
|
199
|
-
// audit-variant-ok: slide container — bg-zinc-900 brand placeholder + snap/flex layout
|
|
200
|
-
_jsxs(Div, { className: `snap-start flex-none w-full relative self-stretch bg-zinc-900 ${slideHeightClass}`, children: [_jsx(Div, { className: POSITION_FILL, children: _jsx(SlideBackground, { bg: slide.background, legacy: slide.media, mobileLegacy: slide.mobileMedia, isMobile: isMobile, priority: slideIndex === 0 }) }), slide.overlay && (
|
|
201
|
-
// audit-variant-ok: overlay container — POSITION_FILL + FLEX_CENTER + responsive px-lg/16/32 ladder
|
|
202
|
-
_jsxs(Div, { className: `${POSITION_FILL} ${FLEX_CENTER} flex-col text-center md:px-16 lg:px-32`, padding: "x-lg", children: [slide.overlay.subtitle && (_jsx(Text, { color: "inverse", shadow: "sm", className: "stagger-1 !/80 mb-1 md:mb-2 tracking-widest", mdSize: "sm", size: "xs", transform: "uppercase", children: slide.overlay.subtitle })), slide.overlay.title && (
|
|
203
|
-
// audit-variant-ok: hero title — responsive md:text-6xl lg:text-8xl + drop-shadow-2xl over Heading size="4xl" base
|
|
204
|
-
_jsx(Heading, { color: "inverse", level: 1, className: "stagger-2 font-display md:text-6xl lg:text-8xl ! drop-shadow-2xl mb-2 md:mb-4", size: "4xl", children: slide.overlay.title })), slide.overlay.description && (_jsx(Text, { color: "inverse", shadow: "sm", className: "stagger-3 !/90 mb-4 md:mb-8 max-w-2xl mx-auto", mdSize: "lg", lgSize: "xl", size: "sm", children: slide.overlay.description })), slide.overlay.button && (_jsx(Div, { className: "stagger-4", children: _jsx(Button, { variant: slide.overlay.button.variant, size: "sm", onClick: makeButtonClickHandler(slide.overlay.button.link, slide.overlay.button.openInNewTab, push), children: slide.overlay.button.text }) }))] })), hasCards && (
|
|
205
|
-
// audit-variant-ok: cards grid — POSITION_FILL + base padding=md + responsive gap-2 md:gap-4 + md:p-8
|
|
206
|
-
_jsx(Div, { className: `${POSITION_FILL} grid gap-2 md:gap-4 md:p-8`, padding: "md", style: {
|
|
187
|
+
return (_jsxs(Div, { className: `snap-start flex-none w-full relative self-stretch bg-zinc-900 ${slideHeightClass}`, children: [_jsx(Div, { className: POSITION_FILL, children: _jsx(SlideBackground, { bg: slide.background, legacy: slide.media, mobileLegacy: slide.mobileMedia, isMobile: isMobile, priority: slideIndex === 0 }) }), slide.overlay && (_jsxs(Div, { className: `${POSITION_FILL} ${FLEX_CENTER} flex-col text-center md:px-16 lg:px-32`, padding: "x-lg", children: [slide.overlay.subtitle && (_jsx(Text, { color: "inverse", shadow: "sm", className: "stagger-1 !/80 mb-1 md:mb-2 tracking-widest", mdSize: "sm", size: "xs", transform: "uppercase", children: slide.overlay.subtitle })), slide.overlay.title && (_jsx(Heading, { color: "inverse", level: 1, className: "stagger-2 font-display md:text-6xl lg:text-8xl ! drop-shadow-2xl mb-2 md:mb-4", size: "4xl", children: slide.overlay.title })), slide.overlay.description && (_jsx(Text, { color: "inverse", shadow: "sm", className: "stagger-3 !/90 mb-4 md:mb-8 max-w-2xl mx-auto", mdSize: "lg", lgSize: "xl", size: "sm", children: slide.overlay.description })), slide.overlay.button && (_jsx(Div, { className: "stagger-4", children: _jsx(Button, { variant: slide.overlay.button.variant, size: "sm", onClick: makeButtonClickHandler(slide.overlay.button.link, slide.overlay.button.openInNewTab, push), children: slide.overlay.button.text }) }))] })), hasCards && (_jsx(Div, { className: `${POSITION_FILL} grid gap-2 md:gap-4 md:p-8`, padding: "md", style: {
|
|
207
188
|
gridTemplateRows: "repeat(2, 1fr)",
|
|
208
189
|
gridTemplateColumns: isMobile ? "1fr" : "repeat(3, 1fr)",
|
|
209
190
|
alignContent: "center",
|
|
@@ -211,7 +192,5 @@ export function HeroCarousel({ initialSlides, push } = {}) {
|
|
|
211
192
|
}, children: slide.cards.slice(0, 6).map((card) => (_jsx(CarouselCardRenderer, { card: card, isMobile: isMobile, push: push }, card.id))) }))] }, slide.id));
|
|
212
193
|
}) }) }), slides.length > 1 && (_jsx(Row, { gap: "sm", className: "absolute bottom-4 left-1/2 -translate-x-1/2 z-10", children: slides.map((_, index) => (_jsx(Button, { variant: "ghost", className: `relative overflow-hidden rounded-full transition-all duration-500 p-0 !min-h-0 ${index === currentSlide
|
|
213
194
|
? HERO_CAROUSEL_DOT_ACTIVE
|
|
214
|
-
: `${HERO_CAROUSEL_DOT_INACTIVE} hover:bg-white/75`}`, onClick: () => goToSlide(index), "aria-label": `Go to slide ${index + 1}`, children: index === currentSlide && (
|
|
215
|
-
// audit-variant-ok: progress-fill bar — absolute positioned bg-black/20 progress animation
|
|
216
|
-
_jsx(Span, { className: "absolute inset-y-0 left-0 bg-black/20 animate-[progress-fill_4s_linear_forwards]", rounded: "full", "aria-hidden": "true" })) }, index))) })), slides.length > 1 && (_jsxs(Row, { gap: "sm", className: "absolute bottom-4 right-4 z-20", children: [_jsx(Button, { variant: "ghost", className: `p-0 ${HERO_CAROUSEL_ARROW}`, onClick: goPrev, "aria-label": "Previous slide", children: _jsx("svg", { className: "w-7 h-7", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: _jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2.5, d: "M15 19l-7-7 7-7" }) }) }), _jsx(Button, { variant: "ghost", className: `p-0 ${HERO_CAROUSEL_ARROW}`, onClick: goNext, "aria-label": "Next slide", children: _jsx("svg", { className: "w-7 h-7", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: _jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2.5, d: "M9 5l7 7-7 7" }) }) })] }))] }));
|
|
195
|
+
: `${HERO_CAROUSEL_DOT_INACTIVE} hover:bg-white/75`}`, onClick: () => goToSlide(index), "aria-label": `Go to slide ${index + 1}`, children: index === currentSlide && (_jsx(Span, { className: "absolute inset-y-0 left-0 bg-black/20 animate-[progress-fill_4s_linear_forwards]", rounded: "full", "aria-hidden": "true" })) }, index))) })), slides.length > 1 && (_jsxs(Row, { gap: "sm", className: "absolute bottom-4 right-4 z-20", children: [_jsx(Button, { variant: "ghost", className: `p-0 ${HERO_CAROUSEL_ARROW}`, onClick: goPrev, "aria-label": "Previous slide", children: _jsx("svg", { className: "w-7 h-7", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: _jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2.5, d: "M15 19l-7-7 7-7" }) }) }), _jsx(Button, { variant: "ghost", className: `p-0 ${HERO_CAROUSEL_ARROW}`, onClick: goNext, "aria-label": "Next slide", children: _jsx("svg", { className: "w-7 h-7", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: _jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2.5, d: "M9 5l7 7-7 7" }) }) })] }))] }));
|
|
217
196
|
}
|
|
@@ -2,15 +2,11 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { Button, Div, Heading, Section, Text } from "../../../ui";
|
|
3
3
|
export function HeroSection({ section, onCtaClick }) {
|
|
4
4
|
const { content } = section;
|
|
5
|
-
return (
|
|
6
|
-
// audit-variant-ok: hero section — min-h-[60vh] custom + bg-neutral-900 dark surface (Section.tone lacks hero-dark variant); flex+items-center handled by layout/align
|
|
7
|
-
_jsxs(Section, { layout: "flex", align: "center", className: "relative min-h-[60vh] overflow-hidden bg-neutral-900", style: content?.imageUrl
|
|
5
|
+
return (_jsxs(Section, { layout: "flex", align: "center", className: "relative min-h-[60vh] overflow-hidden bg-neutral-900", style: content?.imageUrl
|
|
8
6
|
? {
|
|
9
7
|
backgroundImage: `url(${content.imageUrl})`,
|
|
10
8
|
backgroundSize: "cover",
|
|
11
9
|
backgroundPosition: "center",
|
|
12
10
|
}
|
|
13
|
-
: undefined, children: [_jsx(Div, { surface: "overlay-xs", className: "absolute inset-0" }), _jsxs(Div, { paddingX: "x-page", className: "relative mx-auto max-w-7xl text-center text-white", padding: "y-4xl", children: [content?.title && (_jsx(Heading, { level: 1, className: "leading-tight", smSize: "5xl", size: "4xl", lgSize: "6xl", weight: "bold", children: content.title })), content?.subtitle && (_jsx(Text, { className: "mx-auto mt-4 max-w-2xl opacity-90", size: "lg", children: content.subtitle })), content?.ctaLabel && (
|
|
14
|
-
// audit-variant-ok: hero CTA Button — bespoke white-on-dark CTA + zinc-900 text + hover-neutral; Button.variant lacks light-tone-on-dark
|
|
15
|
-
_jsx(Button, { rounded: "full", onClick: onCtaClick, paddingX: "xl", paddingY: "md", textSize: "sm", weight: "semibold", className: "mt-8 inline-block bg-white text-zinc-900 dark:text-zinc-100 transition hover:bg-neutral-100 dark:bg-neutral-800", children: content.ctaLabel }))] })] }));
|
|
11
|
+
: undefined, children: [_jsx(Div, { surface: "overlay-xs", className: "absolute inset-0" }), _jsxs(Div, { paddingX: "x-page", className: "relative mx-auto max-w-7xl text-center text-white", padding: "y-4xl", children: [content?.title && (_jsx(Heading, { level: 1, className: "leading-tight", smSize: "5xl", size: "4xl", lgSize: "6xl", weight: "bold", children: content.title })), content?.subtitle && (_jsx(Text, { className: "mx-auto mt-4 max-w-2xl opacity-90", size: "lg", children: content.subtitle })), content?.ctaLabel && (_jsx(Button, { rounded: "full", onClick: onCtaClick, paddingX: "xl", paddingY: "md", textSize: "sm", weight: "semibold", className: "mt-8 inline-block bg-white text-zinc-900 dark:text-zinc-100 transition hover:bg-neutral-100 dark:bg-neutral-800", children: content.ctaLabel }))] })] }));
|
|
16
12
|
}
|
|
@@ -14,11 +14,7 @@ function StepCard({ step, visible, delay, }) {
|
|
|
14
14
|
"shadow-md group hover:-translate-y-2 hover:shadow-xl",
|
|
15
15
|
"transition-all duration-300",
|
|
16
16
|
visible ? CLS_VISIBLE : "opacity-0 translate-y-8",
|
|
17
|
-
].join(" "),
|
|
18
|
-
// audit-inline-style-ok: computed timing
|
|
19
|
-
style: { transitionDelay: `${delay}ms` }, "data-section": "howitworkssection-div-340", children: [_jsx(Span, { gradient: "brand", size: "7xl", family: "display", className: "absolute top-4 right-5 opacity-10 select-none pointer-events-none leading-none", "aria-hidden": "true", children: step.number }), _jsx(Row, { textWeight: "bold", textSize: "sm", className: `relative z-10 w-10 h-10 ${badgeBg} text-white mb-5`, align: "center", justify: "center", rounded: "full", shadow: "md", children: step.number }), step.renderIcon && (
|
|
20
|
-
// audit-variant-ok: icon container — bespoke white/80 + dark slate border + dynamic iconBg + fixed w-14/h-14 size
|
|
21
|
-
_jsx(Row, { className: `relative z-10 w-14 h-14 ${iconBg} mb-4 border border-white/80 dark:border-slate-700/50`, align: "center", justify: "center", rounded: "2xl", children: _jsx(Span, { className: `${iconColor}`, "aria-hidden": "true", children: step.renderIcon({ className: "w-6 h-6" }) }) })), _jsx(Heading, { level: 3, className: `relative z-10 ${THEMED_TEXT_PRIMARY} mb-2`, size: "base", weight: "semibold", children: step.title }), _jsx(Text, { className: `relative z-10 ${THEMED_TEXT_SECONDARY} leading-relaxed`, size: "sm", children: step.desc })] }));
|
|
17
|
+
].join(" "), style: { transitionDelay: `${delay}ms` }, "data-section": "howitworkssection-div-340", children: [_jsx(Span, { gradient: "brand", size: "7xl", family: "display", className: "absolute top-4 right-5 opacity-10 select-none pointer-events-none leading-none", "aria-hidden": "true", children: step.number }), _jsx(Row, { textWeight: "bold", textSize: "sm", className: `relative z-10 w-10 h-10 ${badgeBg} text-white mb-5`, align: "center", justify: "center", rounded: "full", shadow: "md", children: step.number }), step.renderIcon && (_jsx(Row, { className: `relative z-10 w-14 h-14 ${iconBg} mb-4 border border-white/80 dark:border-slate-700/50`, align: "center", justify: "center", rounded: "2xl", children: _jsx(Span, { className: `${iconColor}`, "aria-hidden": "true", children: step.renderIcon({ className: "w-6 h-6" }) }) })), _jsx(Heading, { level: 3, className: `relative z-10 ${THEMED_TEXT_PRIMARY} mb-2`, size: "base", weight: "semibold", children: step.title }), _jsx(Text, { className: `relative z-10 ${THEMED_TEXT_SECONDARY} leading-relaxed`, size: "sm", children: step.desc })] }));
|
|
22
18
|
}
|
|
23
19
|
// --- Section -----------------------------------------------------------------
|
|
24
20
|
export function HowItWorksSection({ title, subtitle, pillLabel, ctaLabel, onCtaClick, steps, className = "", }) {
|
|
@@ -38,7 +34,5 @@ export function HowItWorksSection({ title, subtitle, pillLabel, ctaLabel, onCtaC
|
|
|
38
34
|
observer.observe(el);
|
|
39
35
|
return () => observer.disconnect();
|
|
40
36
|
}, []);
|
|
41
|
-
return (_jsx(Section, { ref: sectionRef, className: `${className}`, surface: "muted", padding: "xl", children: _jsxs(Div, { className: "max-w-6xl mx-auto", children: [_jsxs(Div, { className: `text-center mb-12 transition-all duration-700 ${visible ? CLS_VISIBLE : "opacity-0 translate-y-4"}`, children: [pillLabel && (
|
|
42
|
-
// audit-variant-ok: eyebrow pill — primary-500/30 border + primary-500/10 bg + tracking-[0.2em] + backdrop-blur-sm bespoke composite
|
|
43
|
-
_jsx(Div, { layout: "inline-flex", gap: "2", align: "center", textWeight: "medium", textSize: "xs", className: "mb-4 border border-primary-500/30 bg-primary-500/10 py-1.5 tracking-[0.2em] uppercase text-primary-700 dark:text-primary-400 backdrop-blur-sm", padding: "x-md", rounded: "full", children: pillLabel })), _jsx(Heading, { level: 2, className: `${themed.textPrimary} mb-3`, size: "3xl", mdSize: "4xl", weight: "bold", children: title }), subtitle && (_jsx(Text, { className: `${themed.textSecondary} max-w-xl mx-auto`, size: "base", children: subtitle }))] }), _jsx(Grid, { gap: "lg", className: "grid-cols-1 md:grid-cols-3 xl:grid-cols-3 2xl:grid-cols-3 mb-10", children: steps.map((step, i) => (_jsx(StepCard, { step: step, visible: visible, delay: i * 150 }, step.number))) }), ctaLabel && onCtaClick && (_jsx(Div, { className: `text-center transition-all duration-700 delay-500 ${visible ? CLS_VISIBLE : "opacity-0 translate-y-4"}`, children: _jsx(Button, { variant: "primary", size: "lg", onClick: onCtaClick, children: ctaLabel }) }))] }) }));
|
|
37
|
+
return (_jsx(Section, { ref: sectionRef, className: `${className}`, surface: "muted", padding: "xl", children: _jsxs(Div, { className: "max-w-6xl mx-auto", children: [_jsxs(Div, { className: `text-center mb-12 transition-all duration-700 ${visible ? CLS_VISIBLE : "opacity-0 translate-y-4"}`, children: [pillLabel && (_jsx(Div, { layout: "inline-flex", gap: "2", align: "center", textWeight: "medium", textSize: "xs", className: "mb-4 border border-primary-500/30 bg-primary-500/10 py-1.5 tracking-[0.2em] uppercase text-primary-700 dark:text-primary-400 backdrop-blur-sm", padding: "x-md", rounded: "full", children: pillLabel })), _jsx(Heading, { level: 2, className: `${themed.textPrimary} mb-3`, size: "3xl", mdSize: "4xl", weight: "bold", children: title }), subtitle && (_jsx(Text, { className: `${themed.textSecondary} max-w-xl mx-auto`, size: "base", children: subtitle }))] }), _jsx(Grid, { gap: "lg", className: "grid-cols-1 md:grid-cols-3 xl:grid-cols-3 2xl:grid-cols-3 mb-10", children: steps.map((step, i) => (_jsx(StepCard, { step: step, visible: visible, delay: i * 150 }, step.number))) }), ctaLabel && onCtaClick && (_jsx(Div, { className: `text-center transition-all duration-700 delay-500 ${visible ? CLS_VISIBLE : "opacity-0 translate-y-4"}`, children: _jsx(Button, { variant: "primary", size: "lg", onClick: onCtaClick, children: ctaLabel }) }))] }) }));
|
|
44
38
|
}
|
|
@@ -89,36 +89,28 @@ export async function MarketplaceHomepageView({ adSlots, newsletterFormSlot, onB
|
|
|
89
89
|
// components only read display fields that are present on both document and item shapes.
|
|
90
90
|
const sectionData = {
|
|
91
91
|
products: productsResult?.items?.length
|
|
92
|
-
// audit-unknown-ok: TS structural escape — ProductItem
|
|
93
92
|
? productsResult.items
|
|
94
93
|
: undefined,
|
|
95
94
|
auctions: auctionsResult?.items?.length
|
|
96
|
-
// audit-unknown-ok: TS structural escape — ProductItem
|
|
97
95
|
? auctionsResult.items
|
|
98
96
|
: undefined,
|
|
99
97
|
preOrders: preOrdersResult?.items?.length
|
|
100
|
-
// audit-unknown-ok: TS structural escape — ProductItem
|
|
101
98
|
? preOrdersResult.items
|
|
102
99
|
: undefined,
|
|
103
100
|
categories: categoriesResult?.length
|
|
104
|
-
// audit-unknown-ok: TS structural escape — CategoryItem
|
|
105
101
|
? categoriesResult
|
|
106
102
|
: undefined,
|
|
107
103
|
brands: brandsResult?.length
|
|
108
|
-
// audit-unknown-ok: TS structural escape — CategoryItem
|
|
109
104
|
? brandsResult
|
|
110
105
|
: undefined,
|
|
111
106
|
bundles: bundlesResult?.length ? bundlesResult : undefined,
|
|
112
107
|
stores: storesResult?.items?.length
|
|
113
|
-
// audit-unknown-ok: TS structural escape — StoreListItem
|
|
114
108
|
? storesResult.items
|
|
115
109
|
: undefined,
|
|
116
110
|
blog: blogResult?.length
|
|
117
|
-
// audit-unknown-ok: TS structural escape — BlogPost
|
|
118
111
|
? blogResult
|
|
119
112
|
: undefined,
|
|
120
113
|
events: eventsResult?.items?.length
|
|
121
|
-
// audit-unknown-ok: TS structural escape — EventItem
|
|
122
114
|
? eventsResult.items
|
|
123
115
|
: undefined,
|
|
124
116
|
};
|
|
@@ -28,17 +28,9 @@ export function NewsletterBanner({ onSubscribe, eyebrow = "STAY CONNECTED", head
|
|
|
28
28
|
setLoading(false);
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
return (_jsxs(Section, { padding: "y-6xl", className: "relative overflow-hidden",
|
|
32
|
-
// audit-inline-style-ok: dynamic CSS
|
|
33
|
-
style: {
|
|
31
|
+
return (_jsxs(Section, { padding: "y-6xl", className: "relative overflow-hidden", style: {
|
|
34
32
|
background: "var(--newsletter-bg, linear-gradient(135deg, var(--color-primary, #1e40af) 0%, var(--color-secondary, #7c3aed) 100%))",
|
|
35
|
-
}, children: [_jsx(Div, { className: "pointer-events-none absolute -top-20 -right-20 h-60 w-60 border border-white/[0.06]", rounded: "full" }), _jsx(Div, { className: "pointer-events-none absolute -bottom-16 -left-16 h-48 w-48 border border-dashed border-white/[0.08]", rounded: "full" }), _jsxs(Div, { className: "relative mx-auto max-w-2xl text-center sm:px-6", padding: "x-md", children: [_jsx(Span, { color: "inverse", size: "xs", weight: "semibold", className: "mb-4 inline-flex border border-white/20 tracking-widest /70", rounded: "full", padding: "pill-md", transform: "uppercase", children: eyebrow }), _jsx(Heading, { color: "inverse", level: 2, smSize: "4xl", size: "3xl", weight: "bold", children: heading }), _jsx(Text, { color: "inverse", className: "mt-4 /60", children: subheading }), success ? (
|
|
36
|
-
// audit-variant-ok: newsletter success message — translucent white/20 border + bg-white/10 over inverse background; Text lacks bg/rounded/border variants on top of color="inverse"
|
|
37
|
-
_jsx(Text, { paddingY: "md", color: "inverse", className: "mt-8 rounded-xl border border-white/20 bg-white/10 px-6", size: "sm", weight: "semibold", children: successMessage })) : (
|
|
38
|
-
// audit-variant-ok: newsletter form — flex+gap-3 layout; Form lacks layout/gap variants (FormShell is the typed alternative for multi-step)
|
|
39
|
-
_jsxs(Form, { onSubmit: handleSubmit, className: "mt-8 flex gap-3", children: [_jsx(FieldInput, { name: "email", type: "email", value: email, onChange: setEmail, placeholder: placeholder, required: true, className: "flex-1" }), _jsx(Button, { rounded: "xl", type: "submit", disabled: loading, variant: "primary", paddingX: "lg", textSize: "sm", className: "shrink-0 py-3 font-bold transition-opacity disabled:opacity-60",
|
|
40
|
-
// audit-inline-style-ok: dynamic CSS
|
|
41
|
-
style: {
|
|
33
|
+
}, children: [_jsx(Div, { className: "pointer-events-none absolute -top-20 -right-20 h-60 w-60 border border-white/[0.06]", rounded: "full" }), _jsx(Div, { className: "pointer-events-none absolute -bottom-16 -left-16 h-48 w-48 border border-dashed border-white/[0.08]", rounded: "full" }), _jsxs(Div, { className: "relative mx-auto max-w-2xl text-center sm:px-6", padding: "x-md", children: [_jsx(Span, { color: "inverse", size: "xs", weight: "semibold", className: "mb-4 inline-flex border border-white/20 tracking-widest /70", rounded: "full", padding: "pill-md", transform: "uppercase", children: eyebrow }), _jsx(Heading, { color: "inverse", level: 2, smSize: "4xl", size: "3xl", weight: "bold", children: heading }), _jsx(Text, { color: "inverse", className: "mt-4 /60", children: subheading }), success ? (_jsx(Text, { paddingY: "md", color: "inverse", className: "mt-8 rounded-xl border border-white/20 bg-white/10 px-6", size: "sm", weight: "semibold", children: successMessage })) : (_jsxs(Form, { onSubmit: handleSubmit, className: "mt-8 flex gap-3", children: [_jsx(FieldInput, { name: "email", type: "email", value: email, onChange: setEmail, placeholder: placeholder, required: true, className: "flex-1" }), _jsx(Button, { rounded: "xl", type: "submit", disabled: loading, variant: "primary", paddingX: "lg", textSize: "sm", className: "shrink-0 py-3 font-bold transition-opacity disabled:opacity-60", style: {
|
|
42
34
|
background: "var(--color-yellow, #FFE500)",
|
|
43
35
|
color: "#0D0D0D",
|
|
44
36
|
}, children: loading ? "…" : ctaLabel })] })), error && (_jsx(Text, { className: CLS_ERROR_TEXT, children: errorMessage })), _jsx(Text, { color: "inverse", className: "mt-4 /40", size: "xs", children: "No spam, ever. Unsubscribe anytime." })] })] }));
|
|
@@ -8,9 +8,7 @@ const __P = {
|
|
|
8
8
|
export function PromoGrid({ banners, eyebrow = "LIMITED TIME", heading = "HOT DEALS & PROMOS", }) {
|
|
9
9
|
if (banners.length === 0)
|
|
10
10
|
return null;
|
|
11
|
-
return (
|
|
12
|
-
// audit-variant-ok: section — base paddingY=y-2xl + sm:py-16 responsive bump
|
|
13
|
-
_jsx(Section, { className: "sm:py-16", padding: "y-2xl", style: {
|
|
11
|
+
return (_jsx(Section, { className: "sm:py-16", padding: "y-2xl", style: {
|
|
14
12
|
background: "var(--dark-section-alt)",
|
|
15
13
|
borderTop: "1px solid rgba(255,255,255,0.06)",
|
|
16
14
|
borderBottom: "1px solid rgba(255,255,255,0.06)",
|
|
@@ -12,9 +12,7 @@ function SecurityCard({ item, visible, delay, }) {
|
|
|
12
12
|
"rounded-xl border p-5 transition-all duration-500",
|
|
13
13
|
colorClass,
|
|
14
14
|
visible ? "opacity-100 translate-y-0" : "opacity-0 translate-y-4",
|
|
15
|
-
].join(" "),
|
|
16
|
-
// audit-inline-style-ok: computed timing
|
|
17
|
-
style: { transitionDelay: `${delay}ms` }, "data-section": "securityhighlightssection-div-357", children: [item.renderIcon && (_jsx(Row, { className: "w-10 h-10 mb-3", surface: "default", align: "center", justify: "center", rounded: "lg", children: _jsx(Span, { className: iconColorClass, "aria-hidden": "true", children: item.renderIcon({ className: "w-6 h-6" }) }) })), _jsx(Text, { className: "mb-1", weight: "semibold", children: item.title }), _jsx(Text, { variant: "secondary", className: "leading-relaxed", size: "sm", children: item.description })] }));
|
|
15
|
+
].join(" "), style: { transitionDelay: `${delay}ms` }, "data-section": "securityhighlightssection-div-357", children: [item.renderIcon && (_jsx(Row, { className: "w-10 h-10 mb-3", surface: "default", align: "center", justify: "center", rounded: "lg", children: _jsx(Span, { className: iconColorClass, "aria-hidden": "true", children: item.renderIcon({ className: "w-6 h-6" }) }) })), _jsx(Text, { className: "mb-1", weight: "semibold", children: item.title }), _jsx(Text, { variant: "secondary", className: "leading-relaxed", size: "sm", children: item.description })] }));
|
|
18
16
|
}
|
|
19
17
|
// --- Section -----------------------------------------------------------------
|
|
20
18
|
export function SecurityHighlightsSection({ title, subtitle, pillLabel, items, learnMoreHref, learnMoreLabel = "Learn more →", className = "", }) {
|
|
@@ -34,7 +32,5 @@ export function SecurityHighlightsSection({ title, subtitle, pillLabel, items, l
|
|
|
34
32
|
observer.observe(el);
|
|
35
33
|
return () => observer.disconnect();
|
|
36
34
|
}, []);
|
|
37
|
-
return (_jsx(Section, { ref: sectionRef, paddingY: "y-2-5xl", className: className, surface: "muted", paddingX: "x-md", children: _jsxs(Div, { className: "max-w-6xl mx-auto", children: [_jsxs(Div, { className: "text-center mb-10", children: [pillLabel && (
|
|
38
|
-
// audit-variant-ok: eyebrow pill — primary-500/30 border + primary-500/10 bg + tracking-[0.2em] + backdrop-blur-sm
|
|
39
|
-
_jsx(Span, { layout: "inline-flex", gap: "md", size: "xs", weight: "medium", className: "border border-primary-500/30 bg-primary-500/10 px-5 py-1.5 tracking-[0.2em] text-primary-700 dark:text-primary-400 backdrop-blur-sm", rounded: "full", transform: "uppercase", children: pillLabel })), _jsx(Heading, { level: 2, className: `mt-4 ${themed.textPrimary}`, size: "3xl", mdSize: "4xl", weight: "bold", children: title }), subtitle && (_jsx(Text, { variant: "secondary", className: "mt-2 max-w-xl mx-auto", children: subtitle }))] }), _jsx(Grid, { gap: "none", className: "grid-cols-1 sm:grid-cols-2 xl:grid-cols-4 gap-5", children: items.map((item, index) => (_jsx(SecurityCard, { item: item, visible: visible, delay: index * 100 }, item.key))) }), learnMoreHref && (_jsx(Div, { className: "text-center mt-8", children: _jsx(TextLink, { href: learnMoreHref, children: learnMoreLabel }) }))] }) }));
|
|
35
|
+
return (_jsx(Section, { ref: sectionRef, paddingY: "y-2-5xl", className: className, surface: "muted", paddingX: "x-md", children: _jsxs(Div, { className: "max-w-6xl mx-auto", children: [_jsxs(Div, { className: "text-center mb-10", children: [pillLabel && (_jsx(Span, { layout: "inline-flex", gap: "md", size: "xs", weight: "medium", className: "border border-primary-500/30 bg-primary-500/10 px-5 py-1.5 tracking-[0.2em] text-primary-700 dark:text-primary-400 backdrop-blur-sm", rounded: "full", transform: "uppercase", children: pillLabel })), _jsx(Heading, { level: 2, className: `mt-4 ${themed.textPrimary}`, size: "3xl", mdSize: "4xl", weight: "bold", children: title }), subtitle && (_jsx(Text, { variant: "secondary", className: "mt-2 max-w-xl mx-auto", children: subtitle }))] }), _jsx(Grid, { gap: "none", className: "grid-cols-1 sm:grid-cols-2 xl:grid-cols-4 gap-5", children: items.map((item, index) => (_jsx(SecurityCard, { item: item, visible: visible, delay: index * 100 }, item.key))) }), learnMoreHref && (_jsx(Div, { className: "text-center mt-8", children: _jsx(TextLink, { href: learnMoreHref, children: learnMoreLabel }) }))] }) }));
|
|
40
36
|
}
|
|
@@ -63,14 +63,10 @@ export function ShopByCategorySection({ title = "Shop by Category", subtitle, li
|
|
|
63
63
|
const categories = filtered.length > 0 ? filtered : allCategories;
|
|
64
64
|
if (!isLoading && allCategories.length === 0)
|
|
65
65
|
return null;
|
|
66
|
-
return (
|
|
67
|
-
// audit-variant-ok: section — base paddingY=y-2xl + md:py-12 responsive bump (paddingY ladder lacks responsive md-up form)
|
|
68
|
-
_jsx(Section, { className: `md:py-12 ${className}`, surface: "subtle", paddingY: "y-2xl", paddingX: "x-md", children: _jsxs(Div, { className: "mx-auto max-w-7xl", children: [_jsxs(Div, { className: "mb-6 text-center", children: [_jsx(Heading, { level: 2, className: themed.textPrimary, size: "2xl", mdSize: "3xl", weight: "bold", children: title }), subtitle && (_jsx(Text, { variant: "secondary", className: "mt-1", size: "sm", children: subtitle }))] }), hasFilters && !isLoading && (_jsxs(Row, { wrap: true, gap: "sm", className: "mb-4", children: [_jsx(FilterChip, { label: "All", active: activeFilter === "all", onClick: () => setActiveFilter("all") }), rootIds.slice(0, 5).map((id) => {
|
|
66
|
+
return (_jsx(Section, { className: `md:py-12 ${className}`, surface: "subtle", paddingY: "y-2xl", paddingX: "x-md", children: _jsxs(Div, { className: "mx-auto max-w-7xl", children: [_jsxs(Div, { className: "mb-6 text-center", children: [_jsx(Heading, { level: 2, className: themed.textPrimary, size: "2xl", mdSize: "3xl", weight: "bold", children: title }), subtitle && (_jsx(Text, { variant: "secondary", className: "mt-1", size: "sm", children: subtitle }))] }), hasFilters && !isLoading && (_jsxs(Row, { wrap: true, gap: "sm", className: "mb-4", children: [_jsx(FilterChip, { label: "All", active: activeFilter === "all", onClick: () => setActiveFilter("all") }), rootIds.slice(0, 5).map((id) => {
|
|
69
67
|
const cat = allCategories.find((c) => c.id === id);
|
|
70
68
|
if (!cat)
|
|
71
69
|
return null;
|
|
72
70
|
return (_jsx(FilterChip, { label: cat.name, active: activeFilter === id, onClick: () => setActiveFilter(activeFilter === id ? "all" : id) }, id));
|
|
73
|
-
})] })), isLoading ? (
|
|
74
|
-
// audit-variant-ok: loading-row carousel — px-1 nudge spacing; PADDING_MAP x-only lacks px-1
|
|
75
|
-
_jsx(Div, { layout: "flex", gap: "3", className: `${__O.hidden} px-1`, children: Array.from({ length: 6 }).map((_, i) => (_jsx(Div, { className: "flex-none h-[104px] w-[108px] animate-pulse", surface: "subtle", rounded: "xl" }, i))) })) : (_jsx(HorizontalScroller, { items: categories, renderItem: (cat) => _jsx(CategoryChip, { category: cat }), perView: CAROUSEL_PER_VIEW.standard, gap: 16, keyExtractor: (cat) => cat.id, autoScroll: true, autoScrollInterval: 3500, showArrows: true, snapToItems: true, showFadeEdges: true, showScrollbar: false, loop: true, pauseOnHover: true })), cta && !isLoading && (_jsx(Div, { className: "mt-6 text-center", children: _jsx(Link, { href: cta.href, className: CTA_CLASSES[cta.variant], children: cta.label }) })), !cta && viewMoreHref && !isLoading && (_jsx(Div, { className: "mt-6 text-center", children: _jsx(Link, { href: viewMoreHref, className: "inline-flex items-center gap-1 text-sm font-medium text-[var(--appkit-color-primary)] hover:opacity-80", children: viewMoreLabel }) }))] }) }));
|
|
71
|
+
})] })), isLoading ? (_jsx(Div, { layout: "flex", gap: "3", className: `${__O.hidden} px-1`, children: Array.from({ length: 6 }).map((_, i) => (_jsx(Div, { className: "flex-none h-[104px] w-[108px] animate-pulse", surface: "subtle", rounded: "xl" }, i))) })) : (_jsx(HorizontalScroller, { items: categories, renderItem: (cat) => _jsx(CategoryChip, { category: cat }), perView: CAROUSEL_PER_VIEW.standard, gap: 16, keyExtractor: (cat) => cat.id, autoScroll: true, autoScrollInterval: 3500, showArrows: true, snapToItems: true, showFadeEdges: true, showScrollbar: false, loop: true, pauseOnHover: true })), cta && !isLoading && (_jsx(Div, { className: "mt-6 text-center", children: _jsx(Link, { href: cta.href, className: CTA_CLASSES[cta.variant], children: cta.label }) })), !cta && viewMoreHref && !isLoading && (_jsx(Div, { className: "mt-6 text-center", children: _jsx(Link, { href: viewMoreHref, className: "inline-flex items-center gap-1 text-sm font-medium text-[var(--appkit-color-primary)] hover:opacity-80", children: viewMoreLabel }) }))] }) }));
|
|
76
72
|
}
|
|
@@ -47,9 +47,7 @@ function YouTubeCard({ post, showCaption }) {
|
|
|
47
47
|
const thumbnail = `https://img.youtube.com/vi/${post.videoId}/maxresdefault.jpg`;
|
|
48
48
|
const href = `https://youtu.be/${post.videoId}`;
|
|
49
49
|
const meta = PLATFORM_META.youtube;
|
|
50
|
-
return (_jsxs("a", { href: href, target: "_blank", rel: "noopener noreferrer", className: "group relative block aspect-video w-full overflow-hidden rounded-xl bg-zinc-900 focus:outline-none focus-visible:ring-2 focus-visible:ring-[var(--appkit-color-youtube)]", "aria-label": post.caption ?? `Watch on YouTube`, children: [_jsx("img", { src: thumbnail, alt: post.caption ?? "YouTube video", className: "h-full w-full object-cover transition-transform duration-300 group-hover:scale-105", loading: "lazy" }), _jsx(Row, { className: "absolute inset-0", align: "center", justify: "center", children: _jsx(Row, { className: "h-14 w-14 bg-[var(--appkit-color-youtube)] transition-transform duration-200 group-hover:scale-110", align: "center", justify: "center", rounded: "full", shadow: "lg", children: _jsx("svg", { className: "ml-1 h-6 w-6 text-white", viewBox: "0 0 24 24", fill: "currentColor", children: _jsx("path", { d: "M8 5v14l11-7z" }) }) }) }), _jsxs(Row, { textWeight: "medium", textSize: "xs", className: `absolute right-2 top-2 px-1.5 text-white ${meta.colorClass}`, padding: "y-2xs", align: "center", gap: "xs", rounded: "default", children: [meta.icon, _jsx(Span, { className: "hidden sm:inline", children: meta.label })] }), post.channelName && (
|
|
51
|
-
// audit-variant-ok: channel badge — absolute-positioned + py-0.5 between-key + backdrop-blur-sm
|
|
52
|
-
_jsx(Div, { textSize: "xs", surface: "overlay-lg", className: "absolute bottom-2 left-2 py-0.5 text-white backdrop-blur-sm", padding: "x-xs", rounded: "default", children: post.channelName })), showCaption && post.caption && (_jsx(Stack, { justify: "end", surface: "overlay-lg", className: `absolute inset-0 ${__P.p3} opacity-0 transition-opacity duration-200 group-hover:opacity-100`, children: _jsx(Text, { color: "inverse", className: "line-clamp-2", size: "xs", children: post.caption }) }))] }));
|
|
50
|
+
return (_jsxs("a", { href: href, target: "_blank", rel: "noopener noreferrer", className: "group relative block aspect-video w-full overflow-hidden rounded-xl bg-zinc-900 focus:outline-none focus-visible:ring-2 focus-visible:ring-[var(--appkit-color-youtube)]", "aria-label": post.caption ?? `Watch on YouTube`, children: [_jsx("img", { src: thumbnail, alt: post.caption ?? "YouTube video", className: "h-full w-full object-cover transition-transform duration-300 group-hover:scale-105", loading: "lazy" }), _jsx(Row, { className: "absolute inset-0", align: "center", justify: "center", children: _jsx(Row, { className: "h-14 w-14 bg-[var(--appkit-color-youtube)] transition-transform duration-200 group-hover:scale-110", align: "center", justify: "center", rounded: "full", shadow: "lg", children: _jsx("svg", { className: "ml-1 h-6 w-6 text-white", viewBox: "0 0 24 24", fill: "currentColor", children: _jsx("path", { d: "M8 5v14l11-7z" }) }) }) }), _jsxs(Row, { textWeight: "medium", textSize: "xs", className: `absolute right-2 top-2 px-1.5 text-white ${meta.colorClass}`, padding: "y-2xs", align: "center", gap: "xs", rounded: "default", children: [meta.icon, _jsx(Span, { className: "hidden sm:inline", children: meta.label })] }), post.channelName && (_jsx(Div, { textSize: "xs", surface: "overlay-lg", className: "absolute bottom-2 left-2 py-0.5 text-white backdrop-blur-sm", padding: "x-xs", rounded: "default", children: post.channelName })), showCaption && post.caption && (_jsx(Stack, { justify: "end", surface: "overlay-lg", className: `absolute inset-0 ${__P.p3} opacity-0 transition-opacity duration-200 group-hover:opacity-100`, children: _jsx(Text, { color: "inverse", className: "line-clamp-2", size: "xs", children: post.caption }) }))] }));
|
|
53
51
|
}
|
|
54
52
|
export function SocialPostCard({ post, showCaption = true, showStats = true }) {
|
|
55
53
|
if (post.platform === "youtube") {
|
|
@@ -9,11 +9,7 @@ function StatCard({ stat, visible, delay, isLast, }) {
|
|
|
9
9
|
"transition-all duration-700",
|
|
10
10
|
visible ? "translate-y-0 opacity-100" : "translate-y-6 opacity-0",
|
|
11
11
|
!isLast ? "border-r border-zinc-200 dark:border-slate-700" : "",
|
|
12
|
-
].join(" "),
|
|
13
|
-
// audit-inline-style-ok: computed timing
|
|
14
|
-
style: { transitionDelay: `${delay}ms` }, children: [stat.renderIcon && (
|
|
15
|
-
// audit-variant-ok: icon container — fixed h-14/w-14 + bg-primary-50 + border-primary-100 themed icon-box
|
|
16
|
-
_jsx(Row, { className: "mb-4 h-14 w-14 bg-primary-50 dark:bg-primary-950/40 border border-primary-100 dark:border-primary-900/30", align: "center", justify: "center", rounded: "2xl", children: stat.renderIcon({ className: "w-7 h-7" }) })), _jsx(Heading, { level: 2, variant: "none", gradient: "brand", className: "mb-1 font-display font-black", mdSize: "5xl", size: "4xl", children: stat.value }), _jsx(Text, { variant: "none", className: "uppercase tracking-widest", color: "muted", size: "xs", weight: "medium", children: stat.label })] }));
|
|
12
|
+
].join(" "), style: { transitionDelay: `${delay}ms` }, children: [stat.renderIcon && (_jsx(Row, { className: "mb-4 h-14 w-14 bg-primary-50 dark:bg-primary-950/40 border border-primary-100 dark:border-primary-900/30", align: "center", justify: "center", rounded: "2xl", children: stat.renderIcon({ className: "w-7 h-7" }) })), _jsx(Heading, { level: 2, variant: "none", gradient: "brand", className: "mb-1 font-display font-black", mdSize: "5xl", size: "4xl", children: stat.value }), _jsx(Text, { variant: "none", className: "uppercase tracking-widest", color: "muted", size: "xs", weight: "medium", children: stat.label })] }));
|
|
17
13
|
}
|
|
18
14
|
// --- Sectmon -----------------------------------------------------------------
|
|
19
15
|
export function StatsCounterSection({ stats, className = "", }) {
|
|
@@ -46,9 +46,7 @@ export function TrustBadges({ badges }) {
|
|
|
46
46
|
background: "var(--section-bg)",
|
|
47
47
|
borderTop: "var(--section-border)",
|
|
48
48
|
borderBottom: "var(--section-border)",
|
|
49
|
-
}, children: _jsx(Div, { className: "mx-auto max-w-7xl sm:py-10", paddingY: "y-lg", paddingX: "x-md", children: _jsx(Div, { layout: "grid", gap: "6", className: "grid-cols-2 sm:grid-cols-4", children: items.map((badge) => (
|
|
50
|
-
// audit-variant-ok: badge Stack — base flex-col + sm:flex-row + sm:gap-4 responsive direction + text-align flip
|
|
51
|
-
_jsxs(Stack, { className: "text-center sm:flex-row sm:items-center sm:text-left sm:gap-4", align: "center", gap: "sm", children: [_jsx(Row, { className: "h-12 w-12 shrink-0", align: "center", justify: "center", rounded: "full", style: {
|
|
49
|
+
}, children: _jsx(Div, { className: "mx-auto max-w-7xl sm:py-10", paddingY: "y-lg", paddingX: "x-md", children: _jsx(Div, { layout: "grid", gap: "6", className: "grid-cols-2 sm:grid-cols-4", children: items.map((badge) => (_jsxs(Stack, { className: "text-center sm:flex-row sm:items-center sm:text-left sm:gap-4", align: "center", gap: "sm", children: [_jsx(Row, { className: "h-12 w-12 shrink-0", align: "center", justify: "center", rounded: "full", style: {
|
|
52
50
|
background: "rgba(240,196,23,0.12)",
|
|
53
51
|
color: "var(--color-red)",
|
|
54
52
|
border: "2px solid var(--border-ink)",
|
|
@@ -8,9 +8,7 @@ function TrustFeatureCard({ item, visible, delay, }) {
|
|
|
8
8
|
"flex flex-col items-center text-center p-4",
|
|
9
9
|
"transition-all duration-500",
|
|
10
10
|
visible ? "opacity-100 translate-y-0" : "opacity-0 translate-y-4",
|
|
11
|
-
].join(" "),
|
|
12
|
-
// audit-inline-style-ok: computed timing
|
|
13
|
-
style: { transitionDelay: `${delay}ms` }, "data-section": "trustfeaturessection-div-373", children: [_jsx(Row, { className: "h-14 w-14 bg-primary-50 dark:bg-primary-950/40 border border-primary-100 dark:border-primary-900/30 flex-shrink-0", align: "center", justify: "center", rounded: "2xl", children: item.renderIcon ? (item.renderIcon({ className: "w-7 h-7" })) : (_jsx(Span, { className: "text-primary-600 dark:text-secondary-400", size: "2xl", "aria-hidden": "true", children: "\u2713" })) }), _jsx(Heading, { level: 3, className: "mt-3 mb-1 tracking-wide uppercase", color: "primary", size: "sm", weight: "bold", children: item.title }), _jsx(Text, { className: "leading-relaxed", color: "muted", size: "xs", children: item.description })] }));
|
|
11
|
+
].join(" "), style: { transitionDelay: `${delay}ms` }, "data-section": "trustfeaturessection-div-373", children: [_jsx(Row, { className: "h-14 w-14 bg-primary-50 dark:bg-primary-950/40 border border-primary-100 dark:border-primary-900/30 flex-shrink-0", align: "center", justify: "center", rounded: "2xl", children: item.renderIcon ? (item.renderIcon({ className: "w-7 h-7" })) : (_jsx(Span, { className: "text-primary-600 dark:text-secondary-400", size: "2xl", "aria-hidden": "true", children: "\u2713" })) }), _jsx(Heading, { level: 3, className: "mt-3 mb-1 tracking-wide uppercase", color: "primary", size: "sm", weight: "bold", children: item.title }), _jsx(Text, { className: "leading-relaxed", color: "muted", size: "xs", children: item.description })] }));
|
|
14
12
|
}
|
|
15
13
|
// --- Single strip-variant item -----------------------------------------------
|
|
16
14
|
function TrustStripItem({ item }) {
|