@mohasinac/appkit 4.53.2 → 4.54.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/.build-stamp.json +3 -3
- package/dist/_internal/server/features/auth/capabilities.js +7 -5
- package/dist/_internal/server/features/checkout/actions.d.ts +22 -6
- package/dist/_internal/server/features/checkout/actions.js +96 -51
- package/dist/_internal/server/features/checkout/index.d.ts +1 -1
- package/dist/_internal/server/features/checkout/index.js +1 -1
- package/dist/_internal/server/features/checkout/supplier-identity.js +28 -6
- package/dist/_internal/server/features/orders/adapters.js +1 -3
- package/dist/_internal/server/features/products/listing-tab-counts.js +81 -25
- package/dist/_internal/server/features/search/index-build/sources.js +43 -2
- package/dist/_internal/server/features/site-settings/adapters.js +1 -1
- package/dist/_internal/server/features/stores/adapters.d.ts +1 -1
- package/dist/_internal/server/features/stores/adapters.js +0 -1
- package/dist/_internal/server/jobs/core/analyticsAlertEvaluate.js +2 -5
- package/dist/_internal/server/jobs/core/jobRunners.js +0 -10
- package/dist/_internal/server/jobs/core/onOrderCreate.js +10 -104
- package/dist/_internal/server/jobs/core/onOrderStatusChange.d.ts +0 -2
- package/dist/_internal/server/jobs/core/onOrderStatusChange.js +0 -1
- package/dist/_internal/server/jobs/core/onScamReportCreate.js +0 -1
- package/dist/_internal/server/jobs/core/onScamReportRejected.js +0 -1
- package/dist/_internal/server/jobs/core/onScamReportVerified.js +0 -1
- package/dist/_internal/server/jobs/core/paymentWindowTimeout.js +0 -1
- package/dist/_internal/server/jobs/core/pendingOrderTimeout.js +0 -1
- package/dist/_internal/server/notifications/channel-health.d.ts +7 -3
- package/dist/_internal/server/notifications/channel-health.js +2 -2
- package/dist/_internal/server/notifications/send-guard.d.ts +1 -1
- package/dist/_internal/server/notifications/send-guard.js +2 -4
- package/dist/_internal/shared/actions/action-registry.d.ts +1 -1
- package/dist/_internal/shared/actions/action-registry.js +128 -28
- package/dist/_internal/shared/checkout/order-math.d.ts +1 -1
- package/dist/_internal/shared/checkout/order-math.js +1 -1
- package/dist/_internal/shared/features/categories/bundle-copy.d.ts +1 -1
- package/dist/_internal/shared/features/checkout/config.d.ts +0 -2
- package/dist/_internal/shared/features/checkout/config.js +0 -2
- package/dist/_internal/shared/features/messaging/config.d.ts +7 -5
- package/dist/_internal/shared/features/messaging/config.js +1 -4
- package/dist/_internal/shared/features/site-settings/fees.d.ts +0 -2
- package/dist/_internal/shared/features/site-settings/fees.js +0 -2
- package/dist/_internal/shared/features/site-settings/supplier-of-record.d.ts +56 -0
- package/dist/_internal/shared/features/site-settings/supplier-of-record.js +57 -0
- package/dist/_internal/shared/fees/calculator.d.ts +0 -8
- package/dist/_internal/shared/fees/calculator.js +0 -7
- package/dist/_internal/shared/listing-types/tiers.d.ts +94 -0
- package/dist/_internal/shared/listing-types/tiers.js +150 -0
- package/dist/cli/index.js +0 -2
- package/dist/client.d.ts +25 -4
- package/dist/client.js +36 -5
- package/dist/constants/api-endpoints.d.ts +21 -15
- package/dist/constants/api-endpoints.js +7 -8
- package/dist/constants/field-names.d.ts +1 -0
- package/dist/constants/field-names.js +1 -0
- package/dist/constants/notification-types.d.ts +1 -1
- package/dist/constants/notification-types.js +1 -1
- package/dist/core/integration-keys.d.ts +5 -5
- package/dist/core/integration-keys.js +21 -10
- package/dist/features/about/components/FeesView.js +0 -6
- package/dist/features/about/components/GuidesHubView.js +15 -2
- package/dist/features/account/components/NotificationPreferencesPanel.js +3 -4
- package/dist/features/account/components/UserOrdersView.js +26 -7
- package/dist/features/account/types/index.d.ts +0 -2
- package/dist/features/addresses/utils/postal-autofill.d.ts +39 -0
- package/dist/features/addresses/utils/postal-autofill.js +54 -0
- package/dist/features/admin/actions/notification-actions.d.ts +2 -8
- package/dist/features/admin/actions/notification-actions.js +9 -104
- package/dist/features/admin/components/AdminGuideHubView.js +1 -8
- package/dist/features/admin/components/AdminOrderEditorView.d.ts +1 -1
- package/dist/features/admin/components/AdminOrdersView.js +0 -2
- package/dist/features/admin/components/AdminSectionsView.js +3 -2
- package/dist/features/admin/components/AdminSiteSettingsView.js +22 -68
- package/dist/features/admin/components/AdminStoreEditorView.js +72 -34
- package/dist/features/admin/components/OwnerQuickActions.d.ts +29 -0
- package/dist/features/admin/components/OwnerQuickActions.js +142 -0
- package/dist/features/admin/components/sections/adminSectionsTypes.js +13 -4
- package/dist/features/admin/components/sections/icon-options.d.ts +21 -0
- package/dist/features/admin/components/sections/icon-options.js +23 -0
- package/dist/features/admin/components/sections/sectionTemplates.js +4 -1
- package/dist/features/admin/constants/site-settings-tabs.d.ts +7 -12
- package/dist/features/admin/constants/site-settings-tabs.js +6 -12
- package/dist/features/admin/repository/site-settings.repository.js +1 -1
- package/dist/features/admin/schemas/admin-editor-forms.d.ts +1 -1
- package/dist/features/admin/schemas/admin-editor-forms.js +4 -1
- package/dist/features/admin/schemas/admin-user-form.d.ts +0 -61
- package/dist/features/admin/schemas/admin-user-form.js +3 -44
- package/dist/features/admin/schemas/firestore.d.ts +28 -54
- package/dist/features/admin/schemas/firestore.js +40 -18
- package/dist/features/auctions/components/AuctionDetailPageView.js +4 -3
- package/dist/features/auctions/components/MarketplaceAuctionCard.d.ts +11 -1
- package/dist/features/auctions/components/MarketplaceAuctionCard.js +9 -2
- package/dist/features/auth/checkout-value-otp.d.ts +1 -1
- package/dist/features/auth/checkout-value-otp.js +1 -1
- package/dist/features/auth/permissions/constants.d.ts +29 -2
- package/dist/features/auth/permissions/constants.js +67 -1
- package/dist/features/blog/components/BlogFeaturedCard.d.ts +11 -1
- package/dist/features/blog/components/BlogFeaturedCard.js +9 -2
- package/dist/features/cart/components/CartDrawer.js +3 -2
- package/dist/features/cart/components/CartGroupLineRow.js +2 -1
- package/dist/features/cart/components/CartPriceBreakdown.d.ts +0 -2
- package/dist/features/cart/components/CartPriceBreakdown.js +1 -1
- package/dist/features/cart/components/StoreAddonsPicker.d.ts +2 -5
- package/dist/features/cart/components/StoreAddonsPicker.js +4 -5
- package/dist/features/cart/hooks/useAddToCart.js +10 -5
- package/dist/features/cart/repository/cart.repository.js +1 -2
- package/dist/features/cart/schemas/firestore.d.ts +1 -2
- package/dist/features/cart/utils/pending-ops.d.ts +11 -1
- package/dist/features/cart/utils/pending-ops.js +14 -2
- package/dist/features/categories/components/BrandDetailPageView.js +2 -1
- package/dist/features/categories/components/BundleDetailView.js +2 -1
- package/dist/features/categories/components/CategoryDetailPageView.js +2 -1
- package/dist/features/categories/components/CategoryGrid.d.ts +11 -1
- package/dist/features/categories/components/CategoryGrid.js +9 -2
- package/dist/features/checkout/actions/checkout-value-otp-actions.d.ts +10 -5
- package/dist/features/checkout/actions/checkout-value-otp-actions.js +2 -88
- package/dist/features/classified/components/ClassifiedDetailPageView.js +2 -1
- package/dist/features/digital-codes/components/DigitalCodeDetailPageView.js +2 -1
- package/dist/features/events/components/EventCard.d.ts +11 -1
- package/dist/features/events/components/EventCard.js +9 -2
- package/dist/features/grouped/components/GroupedListingDetailView.js +3 -1
- package/dist/features/homepage/components/CTABannerSection.d.ts +3 -1
- package/dist/features/homepage/components/CTABannerSection.js +6 -3
- package/dist/features/homepage/components/HeroCarousel.js +8 -6
- package/dist/features/homepage/components/MarketplaceHomepageView.js +33 -7
- package/dist/features/homepage/components/SectionCarousel.js +13 -5
- package/dist/features/homepage/components/SecurityHighlightsSection.d.ts +8 -3
- package/dist/features/homepage/components/SecurityHighlightsSection.js +2 -2
- package/dist/features/homepage/components/StatsCounterSection.d.ts +9 -4
- package/dist/features/homepage/components/StatsCounterSection.js +2 -2
- package/dist/features/homepage/components/TestimonialsCarousel.js +1 -1
- package/dist/features/homepage/components/TrustFeaturesSection.d.ts +18 -4
- package/dist/features/homepage/components/TrustFeaturesSection.js +5 -5
- package/dist/features/homepage/components/WelcomeSection.d.ts +13 -2
- package/dist/features/homepage/components/WelcomeSection.js +3 -3
- package/dist/features/homepage/components/WhatsAppCommunitySection.d.ts +28 -0
- package/dist/features/homepage/components/WhatsAppCommunitySection.js +42 -6
- package/dist/features/homepage/components/WhatsAppGlyph.d.ts +20 -0
- package/dist/features/homepage/components/WhatsAppGlyph.js +20 -0
- package/dist/features/homepage/constants/hero-carousel-styles.d.ts +8 -6
- package/dist/features/homepage/constants/hero-carousel-styles.js +8 -6
- package/dist/features/homepage/constants/section-copy.d.ts +12 -10
- package/dist/features/homepage/constants/section-copy.js +28 -6
- package/dist/features/homepage/constants/stat-icons.d.ts +12 -0
- package/dist/features/homepage/constants/stat-icons.js +17 -0
- package/dist/features/homepage/constants/trust-icon-aliases.d.ts +8 -0
- package/dist/features/homepage/constants/trust-icon-aliases.js +75 -0
- package/dist/features/homepage/lib/section-defaults.d.ts +16 -1
- package/dist/features/homepage/lib/section-defaults.js +24 -4
- package/dist/features/homepage/lib/section-renderer.js +48 -8
- package/dist/features/homepage/schemas/firestore.d.ts +18 -1
- package/dist/features/layout/AppLayoutShell.js +2 -1
- package/dist/features/layout/BottomActions.d.ts +1 -0
- package/dist/features/layout/BottomActions.js +330 -0
- package/dist/features/layout/BottomChrome.d.ts +45 -0
- package/dist/features/layout/BottomChrome.js +5 -17
- package/dist/features/layout/SideActionDock.js +36 -13
- package/dist/features/layout/index.d.ts +2 -7
- package/dist/features/layout/index.js +7 -7
- package/dist/features/layout/useIsDesktop.d.ts +36 -0
- package/dist/features/layout/useIsDesktop.js +48 -0
- package/dist/features/live/components/LiveItemDetailPageView.js +2 -1
- package/dist/features/orders/actions/refund-actions.js +0 -1
- package/dist/features/orders/components/OrderAddonBadges.d.ts +1 -3
- package/dist/features/orders/components/OrderAddonBadges.js +3 -4
- package/dist/features/orders/components/OrderPaymentSummary.js +15 -2
- package/dist/features/orders/components/YourPurchaseStrip.d.ts +24 -0
- package/dist/features/orders/components/YourPurchaseStrip.js +77 -0
- package/dist/features/orders/components/index.d.ts +2 -1
- package/dist/features/orders/components/index.js +1 -1
- package/dist/features/orders/repository/orders.repository.d.ts +0 -8
- package/dist/features/orders/repository/orders.repository.js +0 -2
- package/dist/features/orders/schemas/firestore.d.ts +17 -9
- package/dist/features/orders/types/index.d.ts +2 -5
- package/dist/features/orders/utils/order-announcement-message.d.ts +18 -0
- package/dist/features/orders/utils/order-announcement-message.js +16 -0
- package/dist/features/orders/utils/payment-proof-message.d.ts +20 -0
- package/dist/features/orders/utils/payment-proof-message.js +17 -0
- package/dist/features/parts/components/PartDetailPageView.js +96 -1
- package/dist/features/parts/schemas/firestore.d.ts +247 -0
- package/dist/features/parts/schemas/firestore.js +6 -6
- package/dist/features/pre-orders/components/MarketplacePreorderCard.d.ts +11 -1
- package/dist/features/pre-orders/components/MarketplacePreorderCard.js +10 -3
- package/dist/features/pre-orders/components/PreOrderDetailPageView.js +4 -3
- package/dist/features/products/api/[id]/route.js +8 -1
- package/dist/features/products/api/route.js +16 -4
- package/dist/features/products/components/AvailabilityScopeHint.js +1 -1
- package/dist/features/products/components/InteractiveProductCard.d.ts +7 -1
- package/dist/features/products/components/InteractiveProductCard.js +16 -4
- package/dist/features/products/components/MarketplaceBundleCard.d.ts +11 -1
- package/dist/features/products/components/MarketplaceBundleCard.js +9 -2
- package/dist/features/products/components/MarketplacePrizeDrawCard.d.ts +11 -1
- package/dist/features/products/components/MarketplacePrizeDrawCard.js +9 -2
- package/dist/features/products/components/PrizeDrawDetailPageView.js +2 -1
- package/dist/features/products/components/ProductDetailPageView.js +27 -2
- package/dist/features/products/components/ProductGrid.d.ts +14 -1
- package/dist/features/products/components/ProductGrid.js +22 -5
- package/dist/features/products/components/ProductsIndexListing.js +2 -2
- package/dist/features/reviews/api/[id]/route.js +83 -23
- package/dist/features/reviews/components/PurchaseReviewAffordance.d.ts +6 -0
- package/dist/features/reviews/components/PurchaseReviewAffordance.js +42 -0
- package/dist/features/reviews/components/ReviewFormDrawer.d.ts +34 -0
- package/dist/features/reviews/components/ReviewFormDrawer.js +127 -0
- package/dist/features/reviews/components/index.d.ts +4 -0
- package/dist/features/reviews/components/index.js +2 -0
- package/dist/features/scams/schemas/index.d.ts +10 -10
- package/dist/features/search/action-index/settings-entries.js +0 -9
- package/dist/features/seller/actions/seller-actions.d.ts +1 -1
- package/dist/features/seller/actions/seller-actions.js +49 -3
- package/dist/features/seller/components/SellerPayoutSettingsView.js +30 -2
- package/dist/features/seller/components/SellerProductShell.d.ts +17 -1
- package/dist/features/seller/hooks/useStoreListingEntitlements.d.ts +8 -0
- package/dist/features/seller/hooks/useStoreListingEntitlements.js +70 -0
- package/dist/features/store-extensions/repository/store-extensions.repositories.d.ts +1 -6
- package/dist/features/store-extensions/repository/store-extensions.repositories.js +1 -10
- package/dist/features/store-extensions/schemas/firestore.d.ts +1 -17
- package/dist/features/store-extensions/schemas/firestore.js +0 -10
- package/dist/features/stores/components/InteractiveStoreCard.d.ts +11 -1
- package/dist/features/stores/components/InteractiveStoreCard.js +9 -2
- package/dist/features/stores/components/StoreCapabilitiesGuideView.js +0 -1
- package/dist/features/stores/components/StoreGuideHubView.js +2 -8
- package/dist/features/stores/components/StoreSettingsGuideView.js +2 -6
- package/dist/features/stores/components/index.d.ts +0 -2
- package/dist/features/stores/components/index.js +0 -1
- package/dist/features/stores/repository/store.repository.d.ts +1 -26
- package/dist/features/stores/repository/store.repository.js +5 -60
- package/dist/features/stores/schemas/firestore.d.ts +6 -25
- package/dist/features/stores/schemas/firestore.js +6 -3
- package/dist/features/stores/schemas/index.d.ts +1 -87
- package/dist/features/stores/schemas/index.js +10 -15
- package/dist/features/tester/seed-data/authored/admin__site-system.js +0 -48
- package/dist/features/tester/seed-data/authored/buying__buying-checkout.js +0 -40
- package/dist/features/tester/seed-data/authored/selling__quick-add-minimum-details.js +0 -16
- package/dist/features/tester/seed-data/authored/selling__seller-guide.js +1 -1
- package/dist/features/tester/seed-data/authored/selling__seller-marketing-extras.js +0 -79
- package/dist/features/tester/seed-data/authored/selling__seller-orders.js +1 -1
- package/dist/features/tester/seed-data/tester-checklist-seed-data.js +415 -69
- package/dist/index.d.ts +20 -32
- package/dist/index.js +34 -43
- package/dist/next/routing/route-map.d.ts +2 -8
- package/dist/next/routing/route-map.js +21 -4
- package/dist/providers/db-firebase/base.repository.d.ts +1 -1
- package/dist/providers/db-firebase/base.repository.js +1 -1
- package/dist/providers/payment-razorpay/index.d.ts +125 -0
- package/dist/providers/payment-razorpay/index.js +232 -0
- package/dist/providers/payment-razorpay/signature.d.ts +53 -0
- package/dist/providers/payment-razorpay/signature.js +71 -0
- package/dist/providers/shipping-shiprocket/index.d.ts +98 -0
- package/dist/providers/shipping-shiprocket/index.js +356 -0
- package/dist/providers.d.ts +3 -0
- package/dist/providers.js +3 -0
- package/dist/react/hooks/useCanSeePrices.d.ts +0 -27
- package/dist/react/hooks/useCanSeePrices.js +25 -0
- package/dist/repositories/index.d.ts +1 -1
- package/dist/repositories/index.js +1 -1
- package/dist/schemas/registry.d.ts +10 -115
- package/dist/schemas/registry.js +1 -2
- package/dist/security/pii-encrypt.js +1 -1
- package/dist/seed/_helpers/category-forest.js +27 -0
- package/dist/seed/_helpers/category-parts-glossary-map.js +1816 -88
- package/dist/seed/_helpers/category-parts.d.ts +1 -1
- package/dist/seed/_helpers/category-parts.js +13399 -3019
- package/dist/seed/carousel-slides-seed-data.js +47 -10
- package/dist/seed/categories-seed-data.js +48 -6
- package/dist/seed/faq-seed-data.js +2 -2
- package/dist/seed/homepage-sections-seed-data.js +286 -54
- package/dist/seed/index.d.ts +1 -1
- package/dist/seed/index.js +1 -1
- package/dist/seed/manifest.d.ts +1 -1
- package/dist/seed/manifest.js +1 -2
- package/dist/seed/model-composition-seed-data.js +6 -8
- package/dist/seed/part-glossary/chunk0.d.ts +9 -0
- package/dist/seed/part-glossary/chunk0.js +35448 -0
- package/dist/seed/part-glossary/chunk1.d.ts +9 -0
- package/dist/seed/part-glossary/chunk1.js +40494 -0
- package/dist/seed/part-glossary/chunk2.d.ts +9 -0
- package/dist/seed/part-glossary/chunk2.js +51242 -0
- package/dist/seed/part-glossary/chunk3.d.ts +9 -0
- package/dist/seed/part-glossary/chunk3.js +53337 -0
- package/dist/seed/part-glossary/chunk4.d.ts +9 -0
- package/dist/seed/part-glossary/chunk4.js +51454 -0
- package/dist/seed/part-glossary-seed-data.d.ts +1 -1
- package/dist/seed/part-glossary-seed-data.js +23 -47483
- package/dist/seed/products-catalogue-seed-data.d.ts +5 -5
- package/dist/seed/products-catalogue-seed-data.js +63936 -13803
- package/dist/seed/site-settings-seed-data.js +34 -35
- package/dist/seed/store-extensions-seed-data.d.ts +1 -2
- package/dist/seed/store-extensions-seed-data.js +1 -23
- package/dist/seed/stores-seed-data.js +0 -1
- package/dist/server-entry.d.ts +1 -1
- package/dist/server-entry.js +1 -1
- package/dist/server.d.ts +8 -10
- package/dist/server.js +16 -22
- package/dist/styles.css +392 -43
- package/dist/tailwind-utilities.css +1 -1
- package/dist/tokens/themes/default-dark.js +1 -1
- package/dist/tokens/themes/default-light.js +2 -1
- package/dist/tokens/tokens.css +6 -2
- package/dist/ui/components/Button.d.ts +11 -0
- package/dist/ui/components/Button.js +11 -0
- package/dist/ui/components/Button.style.css +29 -0
- package/dist/ui/components/CarouselNav.d.ts +57 -0
- package/dist/ui/components/CarouselNav.js +25 -0
- package/dist/ui/components/CarouselNav.style.css +265 -0
- package/dist/ui/components/GatedPrice.js +30 -3
- package/dist/ui/components/GatedPrice.style.css +43 -40
- package/dist/ui/components/HorizontalScroller.d.ts +12 -1
- package/dist/ui/components/HorizontalScroller.js +43 -3
- package/dist/ui/components/ImageMosaic.d.ts +8 -1
- package/dist/ui/components/ImageMosaic.js +3 -2
- package/dist/ui/components/ImageMosaic.style.css +22 -0
- package/dist/ui/components/Layout.style.css +6 -0
- package/dist/ui/components/Semantic.d.ts +3 -2
- package/dist/ui/components/Semantic.js +1 -0
- package/dist/ui/components/Typography.d.ts +2 -0
- package/dist/ui/components/Typography.js +2 -0
- package/dist/ui/components/Typography.style.css +19 -0
- package/dist/ui/components/index.style.css +1 -0
- package/dist/ui/index.d.ts +3 -1
- package/dist/ui/index.js +4 -0
- package/package.json +3 -2
- package/dist/_internal/server/jobs/core/whatsappCatalogImport.d.ts +0 -27
- package/dist/_internal/server/jobs/core/whatsappCatalogImport.js +0 -172
- package/dist/_internal/server/jobs/core/whatsappNotify.d.ts +0 -35
- package/dist/_internal/server/jobs/core/whatsappNotify.js +0 -140
- package/dist/features/admin/components/AdminWhatsAppGuideView.d.ts +0 -2
- package/dist/features/admin/components/AdminWhatsAppGuideView.js +0 -35
- package/dist/features/orders/components/MarketplaceOrderCard.d.ts +0 -36
- package/dist/features/orders/components/MarketplaceOrderCard.js +0 -57
- package/dist/features/stores/components/StoreWhatsAppGuideView.d.ts +0 -3
- package/dist/features/stores/components/StoreWhatsAppGuideView.js +0 -12
- package/dist/features/whatsapp-bot/api/send-status/route.d.ts +0 -12
- package/dist/features/whatsapp-bot/api/send-status/route.js +0 -38
- package/dist/features/whatsapp-bot/api/webhook/route.d.ts +0 -12
- package/dist/features/whatsapp-bot/api/webhook/route.js +0 -43
- package/dist/features/whatsapp-bot/components/SellerWhatsAppSettingsView.d.ts +0 -6
- package/dist/features/whatsapp-bot/components/SellerWhatsAppSettingsView.js +0 -270
- package/dist/features/whatsapp-bot/components/WhatsAppChatButton.d.ts +0 -9
- package/dist/features/whatsapp-bot/components/WhatsAppChatButton.js +0 -7
- package/dist/features/whatsapp-bot/components/index.d.ts +0 -3
- package/dist/features/whatsapp-bot/components/index.js +0 -2
- package/dist/features/whatsapp-bot/helpers/payment-proof-message.d.ts +0 -14
- package/dist/features/whatsapp-bot/helpers/payment-proof-message.js +0 -17
- package/dist/features/whatsapp-bot/helpers/whatsapp.d.ts +0 -52
- package/dist/features/whatsapp-bot/helpers/whatsapp.js +0 -283
- package/dist/features/whatsapp-bot/index.d.ts +0 -3
- package/dist/features/whatsapp-bot/index.js +0 -3
- package/dist/features/whatsapp-bot/manifest.d.ts +0 -2
- package/dist/features/whatsapp-bot/manifest.js +0 -13
- package/dist/features/whatsapp-bot/messages/en.json +0 -7
- package/dist/features/whatsapp-bot/server.d.ts +0 -7
- package/dist/features/whatsapp-bot/server.js +0 -7
- package/dist/features/whatsapp-bot/types/index.d.ts +0 -126
- package/dist/features/whatsapp-bot/types/index.js +0 -1
|
@@ -33,7 +33,6 @@
|
|
|
33
33
|
* @tag consumers:seed/index.ts,seed/runner.ts
|
|
34
34
|
* @tag sideEffects:none
|
|
35
35
|
*/
|
|
36
|
-
import { seedPhoto } from "./_helpers/media.js";
|
|
37
36
|
import { ROUTES } from "../next/routing/route-map.js";
|
|
38
37
|
const NOW = new Date();
|
|
39
38
|
const daysAgo = (n) => new Date(NOW.getTime() - n * 86400000);
|
|
@@ -41,6 +40,44 @@ const daysAgo = (n) => new Date(NOW.getTime() - n * 86400000);
|
|
|
41
40
|
// under a full welcome hero, so a viewport-height slide would push the whole
|
|
42
41
|
// page below the fold.
|
|
43
42
|
const SLIDE_SETTINGS = { autoplayDelayMs: 6000, height: "medium" };
|
|
43
|
+
/**
|
|
44
|
+
* 🛑 Real imagery, from `mediaAssets` rows that already exist.
|
|
45
|
+
*
|
|
46
|
+
* Every background and card on this carousel used to be `seedPhoto(...)`, which
|
|
47
|
+
* since 2026-10-09 returns one of SIX flat solid-colour SVG tiles from
|
|
48
|
+
* `public/images/seed-tiles/` — so the homepage hero was five grey rectangles,
|
|
49
|
+
* and the width/height arguments passed beside them were accepted and ignored.
|
|
50
|
+
* Meanwhile 559 wiki-sourced `mediaAssets` rows were sitting in Storage wired
|
|
51
|
+
* to leaf categories and to nothing on the homepage.
|
|
52
|
+
*
|
|
53
|
+
* These are `/media/<shortId>` paths, which resolve through
|
|
54
|
+
* `mediaAssets/{slug}` → `storagePath` and stream from OUR bucket behind a
|
|
55
|
+
* 30-day immutable cache — one invocation per image per edge per month.
|
|
56
|
+
*
|
|
57
|
+
* 🛑 Never `seedExtMedia()` and never a third-party host here: persisting a
|
|
58
|
+
* remote URL through `/api/media/ext` adds an upstream fetch plus a sharp
|
|
59
|
+
* watermark pass to EVERY render, which is Root Cause #104 — ~900K proxy
|
|
60
|
+
* responses and 52.52 GB of origin transfer against a 10 GB allowance, and a
|
|
61
|
+
* suspended project.
|
|
62
|
+
*
|
|
63
|
+
* 🛑 These are publisher product shots on white, not action photography. They
|
|
64
|
+
* are a floor, not a ceiling — see the shot list in the plan for what should
|
|
65
|
+
* eventually replace them. Each one still carries a `dimOverlay` because the
|
|
66
|
+
* overlay copy is fixed-inverse ink and needs a guaranteed-dark backdrop
|
|
67
|
+
* (Root Cause #67).
|
|
68
|
+
*/
|
|
69
|
+
const MEDIA = {
|
|
70
|
+
franchise: "/media/franchise-beyblade-image",
|
|
71
|
+
genOriginal: "/media/category-beyblade-original-image",
|
|
72
|
+
genMetal: "/media/category-beyblade-metal-image",
|
|
73
|
+
genBurst: "/media/category-beyblade-burst-image",
|
|
74
|
+
genX: "/media/category-beyblade-x-image",
|
|
75
|
+
dranzer: "/media/category-dranzer-f-image",
|
|
76
|
+
dragoon: "/media/category-dragoon-f-image",
|
|
77
|
+
aeroPegasus: "/media/category-aeropegasus-3-70a-image",
|
|
78
|
+
spryzen: "/media/category-spryzen-requiem-s3-image",
|
|
79
|
+
lDrago: "/media/category-l-drago-destructor-f-s-image",
|
|
80
|
+
};
|
|
44
81
|
const _rawSlides = [
|
|
45
82
|
{
|
|
46
83
|
id: "slide-hero-homepage",
|
|
@@ -49,7 +86,7 @@ const _rawSlides = [
|
|
|
49
86
|
active: true,
|
|
50
87
|
background: {
|
|
51
88
|
type: "image",
|
|
52
|
-
url:
|
|
89
|
+
url: MEDIA.franchise,
|
|
53
90
|
dimOverlay: { enabled: true, opacity: 0.55 },
|
|
54
91
|
},
|
|
55
92
|
// The ONE cards slide — and therefore the one slide with no `overlay`.
|
|
@@ -60,7 +97,7 @@ const _rawSlides = [
|
|
|
60
97
|
id: "card-hero-shop-now",
|
|
61
98
|
zone: 1,
|
|
62
99
|
mobileZone: 2,
|
|
63
|
-
background: { type: "image", url:
|
|
100
|
+
background: { type: "image", url: MEDIA.dranzer, dimOverlay: { enabled: true, opacity: 0.45 } },
|
|
64
101
|
content: {
|
|
65
102
|
eyebrow: "Buy now",
|
|
66
103
|
title: "Ready to ship",
|
|
@@ -73,7 +110,7 @@ const _rawSlides = [
|
|
|
73
110
|
id: "card-hero-bid",
|
|
74
111
|
zone: 2,
|
|
75
112
|
mobileZone: 2,
|
|
76
|
-
background: { type: "image", url:
|
|
113
|
+
background: { type: "image", url: MEDIA.lDrago, dimOverlay: { enabled: true, opacity: 0.45 } },
|
|
77
114
|
content: {
|
|
78
115
|
eyebrow: "Bid",
|
|
79
116
|
title: "Live auctions",
|
|
@@ -86,7 +123,7 @@ const _rawSlides = [
|
|
|
86
123
|
id: "card-hero-reserve",
|
|
87
124
|
zone: 3,
|
|
88
125
|
mobileZone: 2,
|
|
89
|
-
background: { type: "image", url:
|
|
126
|
+
background: { type: "image", url: MEDIA.aeroPegasus, dimOverlay: { enabled: true, opacity: 0.45 } },
|
|
90
127
|
content: {
|
|
91
128
|
eyebrow: "Reserve",
|
|
92
129
|
title: "Pre-orders",
|
|
@@ -113,7 +150,7 @@ const _rawSlides = [
|
|
|
113
150
|
// (rejects non-image content-type with 400). MediaVideo watermarks
|
|
114
151
|
// video client-side instead, so the raw external URL is correct here.
|
|
115
152
|
url: "/demo-media/sample-video.mp4",
|
|
116
|
-
thumbnail:
|
|
153
|
+
thumbnail: MEDIA.genMetal,
|
|
117
154
|
dimOverlay: { enabled: true, opacity: 0.5 },
|
|
118
155
|
},
|
|
119
156
|
overlay: {
|
|
@@ -142,7 +179,7 @@ const _rawSlides = [
|
|
|
142
179
|
active: true,
|
|
143
180
|
background: {
|
|
144
181
|
type: "image",
|
|
145
|
-
url:
|
|
182
|
+
url: MEDIA.genBurst,
|
|
146
183
|
dimOverlay: { enabled: true, opacity: 0.5 },
|
|
147
184
|
},
|
|
148
185
|
overlay: {
|
|
@@ -171,7 +208,7 @@ const _rawSlides = [
|
|
|
171
208
|
active: true,
|
|
172
209
|
background: {
|
|
173
210
|
type: "image",
|
|
174
|
-
url:
|
|
211
|
+
url: MEDIA.genX,
|
|
175
212
|
dimOverlay: { enabled: true, opacity: 0.5 },
|
|
176
213
|
},
|
|
177
214
|
overlay: {
|
|
@@ -238,7 +275,7 @@ const _rawSlides = [
|
|
|
238
275
|
active: true,
|
|
239
276
|
background: {
|
|
240
277
|
type: "image",
|
|
241
|
-
url:
|
|
278
|
+
url: MEDIA.genOriginal,
|
|
242
279
|
dimOverlay: { enabled: true, opacity: 0.55 },
|
|
243
280
|
},
|
|
244
281
|
overlay: {
|
|
@@ -305,7 +342,7 @@ const _rawSlides = [
|
|
|
305
342
|
active: false,
|
|
306
343
|
background: {
|
|
307
344
|
type: "image",
|
|
308
|
-
url:
|
|
345
|
+
url: MEDIA.spryzen,
|
|
309
346
|
dimOverlay: { enabled: true, opacity: 0.5 },
|
|
310
347
|
},
|
|
311
348
|
overlay: {
|
|
@@ -57,8 +57,8 @@ import { withCategorySearchTxt } from "./_helpers/search-txt-wrappers.js";
|
|
|
57
57
|
import { CATEGORY_FOREST } from "./_helpers/category-forest.js";
|
|
58
58
|
import { BRAND_ROW_COUNT, buildBrandRows } from "./_helpers/brand-rows.js";
|
|
59
59
|
import { FRANCHISE_ROW_COUNT, buildFranchiseRows } from "./_helpers/franchise-rows.js";
|
|
60
|
-
import { MODEL_LEAF_COUNT } from "./_helpers/category-models.js";
|
|
61
|
-
import { PART_LEAF_COUNT } from "./_helpers/category-parts.js";
|
|
60
|
+
import { MODEL_LEAF_COUNT, MODEL_LEAVES } from "./_helpers/category-models.js";
|
|
61
|
+
import { PART_LEAF_COUNT, PART_LEAVES } from "./_helpers/category-parts.js";
|
|
62
62
|
import { MARKET_BAND_LEAF_IDS } from "./_helpers/category-content.js";
|
|
63
63
|
import { GENERATED_CATEGORY_CONTENT, GENERATED_CATEGORY_CONTENT_COUNT, } from "./_helpers/category-content-generated.js";
|
|
64
64
|
import { GENERATED_CATEGORY_IMAGES, GENERATED_CATEGORY_IMAGE_COUNT, GENERATED_CATEGORY_HASBRO_IMAGES, } from "./_helpers/category-images-generated.js";
|
|
@@ -743,11 +743,53 @@ if (allIds.length !== allCategoryRows.length) {
|
|
|
743
743
|
const tier4Rows = rawCategories.filter((c) => c.tier === 4).length;
|
|
744
744
|
const expectedTier4 = MODEL_LEAF_COUNT + PART_LEAF_COUNT;
|
|
745
745
|
if (tier4Rows !== expectedTier4) {
|
|
746
|
+
/*
|
|
747
|
+
* 🛑 NAME THE DROPPED LEAVES. A count told us 2,626 of 2,711 arrived and
|
|
748
|
+
* nothing more, which is unactionable: the ids are all distinct and every
|
|
749
|
+
* parent key exists in the forest, so the difference is in WHICH parent each
|
|
750
|
+
* leaf hangs off and at what depth — and that is only visible per leaf.
|
|
751
|
+
*
|
|
752
|
+
* The expensive version of this was a session spent inferring the cause from
|
|
753
|
+
* indentation in the forest literal. The cheap version is the set
|
|
754
|
+
* difference, grouped by the parent that owns each missing leaf, which also
|
|
755
|
+
* says the tier it actually landed at. One run names the fix.
|
|
756
|
+
*/
|
|
757
|
+
const reached = new Set(rawCategories.filter((c) => c.tier === 4).map((c) => String(c.id)));
|
|
758
|
+
const tierOf = new Map(rawCategories.map((c) => [String(c.id), c.tier]));
|
|
759
|
+
const declared = [];
|
|
760
|
+
for (const [parent, leaves] of Object.entries(MODEL_LEAVES)) {
|
|
761
|
+
for (const leaf of leaves)
|
|
762
|
+
declared.push({ id: leaf.id, parent });
|
|
763
|
+
}
|
|
764
|
+
for (const [parent, leaves] of Object.entries(PART_LEAVES)) {
|
|
765
|
+
for (const leaf of leaves)
|
|
766
|
+
declared.push({ id: leaf.id, parent });
|
|
767
|
+
}
|
|
768
|
+
const missing = declared.filter((d) => !reached.has(d.id));
|
|
769
|
+
const byParent = new Map();
|
|
770
|
+
for (const m of missing) {
|
|
771
|
+
if (!byParent.has(m.parent)) {
|
|
772
|
+
byParent.set(m.parent, { n: 0, landedAt: new Set(), sample: [] });
|
|
773
|
+
}
|
|
774
|
+
const g = byParent.get(m.parent);
|
|
775
|
+
g.n += 1;
|
|
776
|
+
g.landedAt.add(tierOf.has(m.id) ? `tier ${tierOf.get(m.id)}` : "absent");
|
|
777
|
+
if (g.sample.length < 3)
|
|
778
|
+
g.sample.push(m.id);
|
|
779
|
+
}
|
|
780
|
+
const detail = [...byParent.entries()]
|
|
781
|
+
.sort((a, b) => b[1].n - a[1].n)
|
|
782
|
+
.map(([parent, g]) => ` ${parent}: ${g.n} leaf/leaves landed at ${[...g.landedAt].join("+")} ` +
|
|
783
|
+
`(e.g. ${g.sample.join(", ")})`)
|
|
784
|
+
.join("\n");
|
|
746
785
|
throw new Error(`category seed: ${tier4Rows} tier-4 leaves reached the tree but the generated ` +
|
|
747
|
-
`maps declare ${expectedTier4} (${MODEL_LEAF_COUNT} models + ${PART_LEAF_COUNT} parts)
|
|
748
|
-
`
|
|
749
|
-
`
|
|
750
|
-
`
|
|
786
|
+
`maps declare ${expectedTier4} (${MODEL_LEAF_COUNT} models + ${PART_LEAF_COUNT} parts).\n` +
|
|
787
|
+
` ${missing.length} declared leaf/leaves did not arrive as tier 4, by parent:\n` +
|
|
788
|
+
`${detail}\n` +
|
|
789
|
+
` A parent at the wrong DEPTH puts its leaves at the wrong tier (a leaf is ` +
|
|
790
|
+
`always parentDepth+1); a parent id the forest renamed makes them absent ` +
|
|
791
|
+
`entirely. Fix the forest, then re-run node scripts/gen-category-models.mjs ` +
|
|
792
|
+
`and node scripts/gen-category-parts.mjs.`);
|
|
751
793
|
}
|
|
752
794
|
if (brandRows.length !== BRAND_ROW_COUNT) {
|
|
753
795
|
throw new Error(`category seed: ${brandRows.length} brand rows built, expected ${BRAND_ROW_COUNT}`);
|
|
@@ -1023,14 +1023,14 @@ const faqSeedRecords = [
|
|
|
1023
1023
|
{
|
|
1024
1024
|
id: "faq-notification-preferences",
|
|
1025
1025
|
question: "How do I manage my notifications?",
|
|
1026
|
-
answer: html(`<p>Go to Account → Settings → Notification Preferences. You can toggle each notification type (order updates, auction alerts, price drops, community events) per channel — in-app
|
|
1026
|
+
answer: html(`<p>Go to Account → Settings → Notification Preferences. You can toggle each notification type (order updates, auction alerts, price drops, community events) per channel — in-app and email. High-priority notifications (order shipped, auction won) are always sent in-app and cannot be fully disabled.</p>`),
|
|
1027
1027
|
category: "account_security",
|
|
1028
1028
|
showOnHomepage: false,
|
|
1029
1029
|
showInFooter: false,
|
|
1030
1030
|
isPinned: false,
|
|
1031
1031
|
order: 51,
|
|
1032
1032
|
priority: 5,
|
|
1033
|
-
tags: ["notifications", "settings", "preferences", "
|
|
1033
|
+
tags: ["notifications", "settings", "preferences", "email"],
|
|
1034
1034
|
relatedFAQs: [],
|
|
1035
1035
|
stats: makeStats(700, 35),
|
|
1036
1036
|
seo: { slug: "faq-notification-preferences", metaTitle: "Notification Preferences", metaDescription: "Manage your notification preferences on LetItRip." },
|