@mohasinac/appkit 4.13.1 → 4.15.0

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.
Files changed (493) hide show
  1. package/dist/_internal/client/features/layout/DashboardLayoutClient.js +14 -5
  2. package/dist/_internal/client/features/lottery/LotteryAdminEditView.d.ts +3 -0
  3. package/dist/_internal/client/features/lottery/LotteryAdminEditView.js +6 -0
  4. package/dist/_internal/client/features/lottery/LotteryDetailView.d.ts +8 -0
  5. package/dist/_internal/client/features/lottery/LotteryDetailView.js +4 -1
  6. package/dist/_internal/client/features/lottery/LotteryListView.d.ts +7 -0
  7. package/dist/_internal/client/features/lottery/LotteryListView.js +1 -1
  8. package/dist/_internal/client/features/lottery/PrizeDrawLotteryDetailView.js +4 -1
  9. package/dist/_internal/client/features/lottery/slot-collage-items.d.ts +15 -0
  10. package/dist/_internal/client/features/lottery/slot-collage-items.js +13 -0
  11. package/dist/_internal/server/features/auctions/actions.js +8 -2
  12. package/dist/_internal/server/features/bundles/data.d.ts +16 -0
  13. package/dist/_internal/server/features/bundles/data.js +26 -0
  14. package/dist/_internal/server/features/bundles/index.d.ts +1 -1
  15. package/dist/_internal/server/features/bundles/index.js +1 -1
  16. package/dist/_internal/server/features/cart/service.d.ts +3 -3
  17. package/dist/_internal/server/features/checkout/actions.js +25 -0
  18. package/dist/_internal/server/features/checkout/locked-lines.d.ts +38 -0
  19. package/dist/_internal/server/features/checkout/locked-lines.js +171 -0
  20. package/dist/_internal/server/features/checkout/source-context.d.ts +5 -0
  21. package/dist/_internal/server/features/checkout/source-context.js +157 -0
  22. package/dist/_internal/server/features/homepage/index.d.ts +0 -1
  23. package/dist/_internal/server/features/homepage/index.js +7 -1
  24. package/dist/_internal/server/features/lottery/adapters.js +4 -0
  25. package/dist/_internal/server/features/offers/adapters.d.ts +103 -0
  26. package/dist/_internal/server/features/offers/adapters.js +88 -0
  27. package/dist/_internal/server/features/offers/index.d.ts +2 -0
  28. package/dist/_internal/server/features/offers/index.js +1 -0
  29. package/dist/_internal/server/features/orders/adapters.js +24 -0
  30. package/dist/_internal/server/features/products/data.js +15 -37
  31. package/dist/_internal/server/features/products/index.d.ts +1 -1
  32. package/dist/_internal/server/features/products/index.js +1 -1
  33. package/dist/_internal/server/features/products/list-public.d.ts +46 -20
  34. package/dist/_internal/server/features/products/list-public.js +266 -90
  35. package/dist/_internal/server/features/products/listing-tab-counts.d.ts +44 -0
  36. package/dist/_internal/server/features/products/listing-tab-counts.js +97 -0
  37. package/dist/_internal/server/features/site-settings/adapters.d.ts +51 -0
  38. package/dist/_internal/server/features/site-settings/adapters.js +75 -0
  39. package/dist/_internal/server/features/site-settings/index.d.ts +1 -0
  40. package/dist/_internal/server/features/site-settings/index.js +1 -0
  41. package/dist/_internal/server/features/stores/adapters.d.ts +56 -0
  42. package/dist/_internal/server/features/stores/adapters.js +91 -0
  43. package/dist/_internal/server/features/stores/index.d.ts +1 -0
  44. package/dist/_internal/server/features/stores/index.js +1 -0
  45. package/dist/_internal/server/jobs/core/auctionSettlement.js +56 -2
  46. package/dist/_internal/server/jobs/core/offerExpiry.js +55 -19
  47. package/dist/_internal/server/jobs/core/paymentReviewAutoApprove.d.ts +5 -0
  48. package/dist/_internal/server/jobs/core/paymentReviewAutoApprove.js +33 -1
  49. package/dist/_internal/server/jobs/handlers/messages.d.ts +7 -0
  50. package/dist/_internal/server/jobs/handlers/messages.js +10 -0
  51. package/dist/_internal/shared/actions/action-registry.js +17 -1
  52. package/dist/_internal/shared/checkout/lanes.d.ts +25 -0
  53. package/dist/_internal/shared/checkout/lanes.js +26 -0
  54. package/dist/_internal/shared/features/auctions/config.d.ts +27 -0
  55. package/dist/_internal/shared/features/auctions/config.js +27 -0
  56. package/dist/_internal/shared/features/auctions/schema.d.ts +14 -2
  57. package/dist/_internal/shared/features/auctions/schema.js +13 -1
  58. package/dist/_internal/shared/features/blog/schema.d.ts +2 -2
  59. package/dist/_internal/shared/features/cart/schema.d.ts +20 -15
  60. package/dist/_internal/shared/features/cart/schema.js +15 -0
  61. package/dist/_internal/shared/features/categories/bundle-schemas.d.ts +32 -32
  62. package/dist/_internal/shared/features/emi/schedule.d.ts +24 -3
  63. package/dist/_internal/shared/features/emi/schedule.js +20 -5
  64. package/dist/_internal/shared/features/events/schema.d.ts +2 -2
  65. package/dist/_internal/shared/features/homepage/section-gate.d.ts +14 -0
  66. package/dist/_internal/shared/features/homepage/section-gate.js +51 -0
  67. package/dist/_internal/shared/features/offers/config.d.ts +30 -0
  68. package/dist/_internal/shared/features/offers/config.js +59 -0
  69. package/dist/_internal/shared/features/orders/schema.d.ts +8 -8
  70. package/dist/_internal/shared/features/products/schema.d.ts +30 -30
  71. package/dist/_internal/shared/features/products/to-product-item.js +6 -0
  72. package/dist/_internal/shared/features/reviews/schema.d.ts +2 -2
  73. package/dist/_internal/shared/features/site-settings/fees.d.ts +60 -0
  74. package/dist/_internal/shared/features/site-settings/fees.js +39 -0
  75. package/dist/_internal/shared/features/site-settings/types.d.ts +40 -0
  76. package/dist/_internal/shared/features/site-settings/types.js +1 -0
  77. package/dist/_internal/shared/history/history.d.ts +88 -0
  78. package/dist/_internal/shared/history/history.js +198 -0
  79. package/dist/_internal/shared/history/index.d.ts +4 -0
  80. package/dist/_internal/shared/history/index.js +2 -0
  81. package/dist/_internal/shared/history/types.d.ts +61 -0
  82. package/dist/_internal/shared/history/types.js +6 -0
  83. package/dist/_internal/shared/listing-types/_registry.d.ts +54 -1
  84. package/dist/_internal/shared/listing-types/_registry.js +67 -0
  85. package/dist/_internal/shared/listing-types/art/config.d.ts +3 -0
  86. package/dist/_internal/shared/listing-types/art/config.js +5 -0
  87. package/dist/_internal/shared/listing-types/auction/config.d.ts +13 -0
  88. package/dist/_internal/shared/listing-types/auction/config.js +21 -0
  89. package/dist/_internal/shared/listing-types/availability.d.ts +79 -0
  90. package/dist/_internal/shared/listing-types/availability.js +104 -0
  91. package/dist/_internal/shared/listing-types/capabilities.d.ts +15 -0
  92. package/dist/_internal/shared/listing-types/capabilities.js +12 -0
  93. package/dist/_internal/shared/listing-types/classified/config.d.ts +3 -0
  94. package/dist/_internal/shared/listing-types/classified/config.js +5 -0
  95. package/dist/_internal/shared/listing-types/digital-code/config.d.ts +11 -0
  96. package/dist/_internal/shared/listing-types/digital-code/config.js +22 -2
  97. package/dist/_internal/shared/listing-types/live/config.d.ts +3 -0
  98. package/dist/_internal/shared/listing-types/live/config.js +5 -0
  99. package/dist/_internal/shared/listing-types/pre-order/config.d.ts +3 -0
  100. package/dist/_internal/shared/listing-types/pre-order/config.js +19 -0
  101. package/dist/_internal/shared/listing-types/prize-draw/config.d.ts +11 -0
  102. package/dist/_internal/shared/listing-types/prize-draw/config.js +15 -0
  103. package/dist/_internal/shared/listing-types/standard/config.d.ts +3 -0
  104. package/dist/_internal/shared/listing-types/standard/config.js +5 -0
  105. package/dist/_internal/shared/listing-types/stickers/config.d.ts +3 -0
  106. package/dist/_internal/shared/listing-types/stickers/config.js +5 -0
  107. package/dist/client.d.ts +20 -7
  108. package/dist/client.js +22 -4
  109. package/dist/constants/api-endpoints.d.ts +6 -0
  110. package/dist/constants/api-endpoints.js +2 -0
  111. package/dist/constants/field-names.d.ts +57 -8
  112. package/dist/constants/field-names.js +101 -8
  113. package/dist/constants/table-keys.d.ts +17 -0
  114. package/dist/constants/table-keys.js +17 -0
  115. package/dist/errors/error-codes.d.ts +13 -1
  116. package/dist/errors/error-codes.js +13 -1
  117. package/dist/errors/error-display-map.js +12 -3
  118. package/dist/errors/messages.d.ts +10 -2
  119. package/dist/errors/messages.js +10 -2
  120. package/dist/features/about/components/AboutView.d.ts +3 -0
  121. package/dist/features/about/components/AboutView.js +3 -2
  122. package/dist/features/about/components/PolicyPageView.d.ts +2 -1
  123. package/dist/features/about/components/PolicyPageView.js +61 -23
  124. package/dist/features/about/components/PublicProfileView.js +5 -0
  125. package/dist/features/about/schemas/firestore.d.ts +3 -0
  126. package/dist/features/account/components/UserBidsView.js +12 -4
  127. package/dist/features/account/components/UserOrdersView.js +7 -0
  128. package/dist/features/account/components/UserReturnsView.d.ts +3 -0
  129. package/dist/features/account/components/UserReturnsView.js +17 -1
  130. package/dist/features/account/components/index.d.ts +0 -2
  131. package/dist/features/account/components/index.js +0 -1
  132. package/dist/features/account/schemas/index.d.ts +2 -2
  133. package/dist/features/account/types/index.d.ts +21 -2
  134. package/dist/features/addresses/schemas/index.d.ts +4 -4
  135. package/dist/features/admin/components/AdminArtView.js +8 -3
  136. package/dist/features/admin/components/AdminAuditLogView.js +1 -0
  137. package/dist/features/admin/components/AdminBidsView.js +15 -2
  138. package/dist/features/admin/components/AdminBlogEditorView.js +65 -33
  139. package/dist/features/admin/components/AdminClassifiedView.js +8 -3
  140. package/dist/features/admin/components/AdminDigitalCodesView.js +8 -3
  141. package/dist/features/admin/components/AdminFeatureEditorView.js +35 -6
  142. package/dist/features/admin/components/AdminFeatureFlagsView.js +1 -0
  143. package/dist/features/admin/components/AdminLiveView.js +8 -3
  144. package/dist/features/admin/components/AdminNavEditorView.js +15 -5
  145. package/dist/features/admin/components/AdminNewsletterView.js +18 -2
  146. package/dist/features/admin/components/AdminOffersView.d.ts +4 -0
  147. package/dist/features/admin/components/AdminOffersView.js +230 -0
  148. package/dist/features/admin/components/AdminOrdersView.js +10 -1
  149. package/dist/features/admin/components/AdminPaymentMethodsView.js +24 -4
  150. package/dist/features/admin/components/AdminPrizeDrawsView.js +5 -0
  151. package/dist/features/admin/components/AdminProductsView.js +16 -29
  152. package/dist/features/admin/components/AdminScammerEditorView.d.ts +2 -1
  153. package/dist/features/admin/components/AdminScammerEditorView.js +3 -13
  154. package/dist/features/admin/components/AdminScammersView.js +3 -8
  155. package/dist/features/admin/components/AdminSectionsView.js +32 -23
  156. package/dist/features/admin/components/AdminSessionsView.js +17 -2
  157. package/dist/features/admin/components/AdminSiteSettingsView.js +31 -13
  158. package/dist/features/admin/components/AdminSiteView.js +6 -2
  159. package/dist/features/admin/components/AdminStickersView.js +8 -3
  160. package/dist/features/admin/components/ViewAuditLogEntryModal.js +1 -0
  161. package/dist/features/admin/components/index.d.ts +2 -0
  162. package/dist/features/admin/components/index.js +1 -0
  163. package/dist/features/admin/components/sections/adminSectionsTypes.d.ts +4 -2
  164. package/dist/features/admin/components/sections/adminSectionsTypes.js +45 -27
  165. package/dist/features/admin/constants/filter-tabs.d.ts +89 -0
  166. package/dist/features/admin/constants/filter-tabs.js +56 -0
  167. package/dist/features/admin/schemas/firestore.d.ts +122 -3
  168. package/dist/features/admin/schemas/firestore.js +1 -0
  169. package/dist/features/admin/schemas/homepage-section-form.d.ts +22 -0
  170. package/dist/features/admin/schemas/homepage-section-form.js +68 -0
  171. package/dist/features/admin/schemas/nav-item-form.d.ts +74 -0
  172. package/dist/features/admin/schemas/nav-item-form.js +72 -0
  173. package/dist/features/auctions/actions/bid-actions.d.ts +20 -5
  174. package/dist/features/auctions/actions/bid-actions.js +93 -20
  175. package/dist/features/auctions/components/AuctionBidsTable.d.ts +10 -1
  176. package/dist/features/auctions/components/AuctionBidsTable.js +22 -4
  177. package/dist/features/auctions/components/AuctionDetailPageView.js +11 -6
  178. package/dist/features/auctions/components/AuctionsListView.js +5 -6
  179. package/dist/features/auctions/components/MarketplaceAuctionCard.d.ts +7 -0
  180. package/dist/features/auctions/components/MarketplaceAuctionCard.js +19 -2
  181. package/dist/features/auctions/components/PlaceBidFormClient.d.ts +1 -2
  182. package/dist/features/auctions/components/PlaceBidFormClient.js +8 -4
  183. package/dist/features/auctions/components/bid-detail-fields.d.ts +29 -0
  184. package/dist/features/auctions/components/bid-detail-fields.js +103 -0
  185. package/dist/features/auctions/repository/bid.repository.d.ts +13 -0
  186. package/dist/features/auctions/repository/bid.repository.js +23 -0
  187. package/dist/features/auctions/schemas/firestore.d.ts +17 -0
  188. package/dist/features/auctions/schemas/index.d.ts +12 -12
  189. package/dist/features/audit-log/schemas/firestore.d.ts +14 -0
  190. package/dist/features/audit-log/schemas/firestore.js +7 -0
  191. package/dist/features/auth/permissions/constants.d.ts +1 -1
  192. package/dist/features/auth/permissions/constants.js +10 -1
  193. package/dist/features/blog/actions/blog-actions.d.ts +7 -7
  194. package/dist/features/blog/schemas/blog-form.d.ts +80 -0
  195. package/dist/features/blog/schemas/blog-form.js +100 -0
  196. package/dist/features/blog/schemas/index.d.ts +6 -6
  197. package/dist/features/cart/repository/cart.repository.js +1 -0
  198. package/dist/features/cart/schemas/firestore.d.ts +15 -0
  199. package/dist/features/catalogue/schemas/validation.d.ts +4 -4
  200. package/dist/features/categories/components/BrandDetailPageView.js +23 -40
  201. package/dist/features/categories/components/BrandDetailTabs.d.ts +7 -7
  202. package/dist/features/categories/components/BrandDetailTabs.js +8 -12
  203. package/dist/features/categories/components/BundleCollage.js +1 -1
  204. package/dist/features/categories/components/CategoryDetailPageView.js +53 -57
  205. package/dist/features/categories/components/CategoryDetailTabs.d.ts +10 -8
  206. package/dist/features/categories/components/CategoryDetailTabs.js +11 -16
  207. package/dist/features/categories/components/CategoryProductsListing.js +11 -1
  208. package/dist/features/categories/components/ConcernCard.js +7 -1
  209. package/dist/features/categories/schemas/firestore.d.ts +13 -0
  210. package/dist/features/categories/schemas/index.d.ts +26 -26
  211. package/dist/features/classified/components/ClassifiedDetailPageView.d.ts +16 -1
  212. package/dist/features/classified/components/ClassifiedDetailPageView.js +23 -3
  213. package/dist/features/events/components/AdminEventEditorView.js +32 -54
  214. package/dist/features/events/components/AdminEventEntriesView.js +22 -3
  215. package/dist/features/events/components/AdminEventsView.js +15 -11
  216. package/dist/features/events/components/EventFilters.d.ts +9 -1
  217. package/dist/features/events/components/EventFilters.js +45 -21
  218. package/dist/features/events/components/EventsIndexListing.d.ts +6 -1
  219. package/dist/features/events/components/EventsIndexListing.js +2 -2
  220. package/dist/features/events/components/EventsListPageView.js +13 -4
  221. package/dist/features/events/repository/events.repository.d.ts +17 -0
  222. package/dist/features/events/repository/events.repository.js +27 -0
  223. package/dist/features/events/schemas/event-form.d.ts +113 -0
  224. package/dist/features/events/schemas/event-form.js +82 -0
  225. package/dist/features/events/schemas/firestore.d.ts +12 -0
  226. package/dist/features/events/schemas/firestore.js +12 -0
  227. package/dist/features/events/schemas/index.d.ts +50 -50
  228. package/dist/features/events/types/index.d.ts +11 -0
  229. package/dist/features/events/types/index.js +57 -1
  230. package/dist/features/faq/actions/faq-actions.d.ts +12 -12
  231. package/dist/features/faq/schemas/index.d.ts +8 -8
  232. package/dist/features/filters/FilterFacetSection.d.ts +7 -1
  233. package/dist/features/filters/FilterFacetSection.js +11 -3
  234. package/dist/features/grouped/schemas/grouped-listing-form.d.ts +101 -0
  235. package/dist/features/grouped/schemas/grouped-listing-form.js +89 -0
  236. package/dist/features/grouped/schemas/index.d.ts +4 -4
  237. package/dist/features/homepage/actions/homepage-section-actions.d.ts +11 -3
  238. package/dist/features/homepage/actions/homepage-section-actions.js +33 -1
  239. package/dist/features/homepage/components/AnnouncementBar.d.ts +7 -1
  240. package/dist/features/homepage/components/AnnouncementBar.js +3 -3
  241. package/dist/features/homepage/components/MarketplaceHomepageView.js +20 -6
  242. package/dist/features/homepage/hooks/homepage-query.d.ts +16 -0
  243. package/dist/features/homepage/hooks/homepage-query.js +45 -0
  244. package/dist/features/homepage/hooks/useFeaturedAuctions.d.ts +10 -0
  245. package/dist/features/homepage/hooks/useFeaturedAuctions.js +28 -8
  246. package/dist/features/homepage/hooks/useFeaturedPreOrders.js +17 -8
  247. package/dist/features/homepage/hooks/useFeaturedProducts.js +15 -8
  248. package/dist/features/homepage/schemas/index.d.ts +33 -2
  249. package/dist/features/homepage/schemas/index.js +24 -0
  250. package/dist/features/layout/AppLayoutShell.d.ts +11 -1
  251. package/dist/features/layout/AppLayoutShell.js +15 -14
  252. package/dist/features/layout/BackToTop.d.ts +9 -0
  253. package/dist/features/layout/BackToTop.js +10 -1
  254. package/dist/features/layout/BottomActions.js +28 -25
  255. package/dist/features/layout/BottomChrome.d.ts +34 -0
  256. package/dist/features/layout/BottomChrome.js +55 -0
  257. package/dist/features/layout/BottomNavLayout.d.ts +6 -0
  258. package/dist/features/layout/BottomNavLayout.js +7 -1
  259. package/dist/features/layout/BottomNavbar.js +15 -2
  260. package/dist/features/layout/FooterLayout.js +11 -1
  261. package/dist/features/layout/NavbarLayout.js +1 -1
  262. package/dist/features/layout/TitleBarLayout.d.ts +7 -0
  263. package/dist/features/layout/TitleBarLayout.js +28 -5
  264. package/dist/features/layout/index.d.ts +2 -0
  265. package/dist/features/layout/index.js +1 -0
  266. package/dist/features/lottery/types/index.d.ts +3 -0
  267. package/dist/features/media/MediaPickerModal.js +5 -1
  268. package/dist/features/messages/schemas/index.d.ts +2 -2
  269. package/dist/features/orders/components/OrderScopeTabs.d.ts +20 -0
  270. package/dist/features/orders/components/OrderScopeTabs.js +31 -0
  271. package/dist/features/orders/components/OrderStatusTimeline.d.ts +5 -1
  272. package/dist/features/orders/components/OrderStatusTimeline.js +39 -20
  273. package/dist/features/orders/constants/order-scope.d.ts +48 -0
  274. package/dist/features/orders/constants/order-scope.js +111 -0
  275. package/dist/features/orders/repository/orders.repository.d.ts +54 -7
  276. package/dist/features/orders/repository/orders.repository.js +121 -22
  277. package/dist/features/orders/schemas/firestore.d.ts +152 -0
  278. package/dist/features/orders/schemas/firestore.js +30 -0
  279. package/dist/features/orders/schemas/index.d.ts +18 -18
  280. package/dist/features/orders/types/index.d.ts +35 -7
  281. package/dist/features/pre-orders/components/PreOrdersIndexListing.js +14 -9
  282. package/dist/features/pre-orders/components/PreOrdersListView.js +6 -5
  283. package/dist/features/pre-orders/schemas/index.d.ts +1 -1
  284. package/dist/features/products/actions/product-actions.d.ts +14 -0
  285. package/dist/features/products/actions/product-actions.js +49 -11
  286. package/dist/features/products/api/route.d.ts +12 -0
  287. package/dist/features/products/api/route.js +42 -100
  288. package/dist/features/products/components/ArtStickersListView.js +2 -2
  289. package/dist/features/products/components/AuctionsIndexListing.js +13 -11
  290. package/dist/features/products/components/AvailabilityTabs.d.ts +11 -0
  291. package/dist/features/products/components/AvailabilityTabs.js +47 -0
  292. package/dist/features/products/components/GroupSettingsPanel.js +5 -1
  293. package/dist/features/products/components/MakeOfferButton.js +48 -49
  294. package/dist/features/products/components/PrizeDrawCollage.d.ts +20 -4
  295. package/dist/features/products/components/PrizeDrawCollage.js +9 -1
  296. package/dist/features/products/components/PrizeDrawsIndexListing.js +14 -12
  297. package/dist/features/products/components/PrizeDrawsListingView.js +2 -2
  298. package/dist/features/products/components/PrizeDrawsSection.d.ts +7 -1
  299. package/dist/features/products/components/PrizeDrawsSection.js +23 -18
  300. package/dist/features/products/components/ProductDetailPageView.d.ts +4 -1
  301. package/dist/features/products/components/ProductDetailPageView.js +18 -4
  302. package/dist/features/products/components/ProductForm.js +5 -2
  303. package/dist/features/products/components/ProductGrid.js +6 -1
  304. package/dist/features/products/components/ProductsIndexListing.js +22 -32
  305. package/dist/features/products/components/ProductsIndexPageView.js +6 -9
  306. package/dist/features/products/components/index.d.ts +2 -2
  307. package/dist/features/products/components/index.js +1 -1
  308. package/dist/features/products/config/listing-type-listing-config.d.ts +20 -0
  309. package/dist/features/products/config/listing-type-listing-config.js +22 -10
  310. package/dist/features/products/constants/action-defs.d.ts +2 -0
  311. package/dist/features/products/constants/action-defs.js +6 -0
  312. package/dist/features/products/hooks/useAvailabilityScope.d.ts +13 -0
  313. package/dist/features/products/hooks/useAvailabilityScope.js +19 -0
  314. package/dist/features/products/hooks/useProducts.d.ts +5 -0
  315. package/dist/features/products/hooks/useProducts.js +13 -2
  316. package/dist/features/products/repository/products.repository.d.ts +31 -2
  317. package/dist/features/products/repository/products.repository.js +53 -21
  318. package/dist/features/products/schemas/firestore.d.ts +17 -3
  319. package/dist/features/products/schemas/firestore.js +7 -2
  320. package/dist/features/products/schemas/index.d.ts +64 -64
  321. package/dist/features/products/schemas/product-features.validators.d.ts +79 -6
  322. package/dist/features/products/schemas/product-features.validators.js +63 -0
  323. package/dist/features/products/types/index.d.ts +16 -1
  324. package/dist/features/promotions/schemas/index.d.ts +2 -2
  325. package/dist/features/reviews/schemas/index.d.ts +16 -16
  326. package/dist/features/scams/constants/scammer-status-display.d.ts +28 -0
  327. package/dist/features/scams/constants/scammer-status-display.js +79 -0
  328. package/dist/features/search/schemas/index.d.ts +4 -4
  329. package/dist/features/seller/actions/offer-actions.js +57 -4
  330. package/dist/features/seller/components/OfferPhaseTimeline.d.ts +59 -0
  331. package/dist/features/seller/components/OfferPhaseTimeline.js +107 -0
  332. package/dist/features/seller/components/SellerArtView.js +5 -0
  333. package/dist/features/seller/components/SellerAuctionsView.js +13 -15
  334. package/dist/features/seller/components/SellerBidsView.js +11 -4
  335. package/dist/features/seller/components/SellerClassifiedView.js +5 -0
  336. package/dist/features/seller/components/SellerCouponEditorView.js +17 -17
  337. package/dist/features/seller/components/SellerDigitalCodesView.js +5 -0
  338. package/dist/features/seller/components/SellerLiveView.js +5 -0
  339. package/dist/features/seller/components/SellerOffersView.js +2 -1
  340. package/dist/features/seller/components/SellerOrdersView.js +31 -9
  341. package/dist/features/seller/components/SellerPayoutSettingsView.js +56 -31
  342. package/dist/features/seller/components/SellerPreOrdersView.js +5 -0
  343. package/dist/features/seller/components/SellerPrizeDrawsView.js +14 -16
  344. package/dist/features/seller/components/SellerProductShell.js +7 -1
  345. package/dist/features/seller/components/SellerProductsView.js +11 -8
  346. package/dist/features/seller/components/SellerStickersView.js +5 -0
  347. package/dist/features/seller/components/index.d.ts +0 -2
  348. package/dist/features/seller/components/index.js +0 -1
  349. package/dist/features/seller/repository/offer.repository.d.ts +142 -24
  350. package/dist/features/seller/repository/offer.repository.js +165 -26
  351. package/dist/features/seller/schemas/coupon-form.d.ts +72 -0
  352. package/dist/features/seller/schemas/coupon-form.js +116 -0
  353. package/dist/features/seller/schemas/firestore.d.ts +56 -2
  354. package/dist/features/seller/schemas/firestore.js +27 -0
  355. package/dist/features/seller/schemas/index.d.ts +2 -2
  356. package/dist/features/seller/schemas/offer-forms.d.ts +46 -0
  357. package/dist/features/seller/schemas/offer-forms.js +42 -0
  358. package/dist/features/seller/server.d.ts +0 -1
  359. package/dist/features/seller/server.js +0 -1
  360. package/dist/features/shell/SectionForm.d.ts +99 -0
  361. package/dist/features/shell/SectionForm.js +128 -0
  362. package/dist/features/shell/build-sections.d.ts +63 -0
  363. package/dist/features/shell/build-sections.js +207 -0
  364. package/dist/features/shell/entity-form.d.ts +109 -0
  365. package/dist/features/shell/entity-form.js +96 -0
  366. package/dist/features/shell/field-ui-meta.d.ts +115 -0
  367. package/dist/features/shell/field-ui-meta.js +324 -0
  368. package/dist/features/shell/index.d.ts +8 -0
  369. package/dist/features/shell/index.js +4 -0
  370. package/dist/features/status-history/components/StatusTimeline.d.ts +74 -0
  371. package/dist/features/status-history/components/StatusTimeline.js +46 -0
  372. package/dist/features/status-history/index.d.ts +11 -0
  373. package/dist/features/status-history/index.js +10 -0
  374. package/dist/features/store-extensions/components/ReviewDecisionModal.d.ts +27 -0
  375. package/dist/features/store-extensions/components/ReviewDecisionModal.js +82 -0
  376. package/dist/features/store-extensions/index.d.ts +12 -0
  377. package/dist/features/store-extensions/index.js +12 -0
  378. package/dist/features/store-extensions/schemas/admin-notification-form.d.ts +36 -0
  379. package/dist/features/store-extensions/schemas/admin-notification-form.js +114 -0
  380. package/dist/features/store-extensions/schemas/analytics-forms.d.ts +57 -0
  381. package/dist/features/store-extensions/schemas/analytics-forms.js +158 -0
  382. package/dist/features/store-extensions/schemas/custom-role-form.d.ts +85 -0
  383. package/dist/features/store-extensions/schemas/custom-role-form.js +118 -0
  384. package/dist/features/store-extensions/schemas/firestore.d.ts +21 -1
  385. package/dist/features/store-extensions/schemas/firestore.js +60 -0
  386. package/dist/features/store-extensions/schemas/google-config-form.d.ts +53 -0
  387. package/dist/features/store-extensions/schemas/google-config-form.js +105 -0
  388. package/dist/features/store-extensions/schemas/item-request-create-form.d.ts +28 -0
  389. package/dist/features/store-extensions/schemas/item-request-create-form.js +80 -0
  390. package/dist/features/store-extensions/schemas/listing-template-form.d.ts +78 -0
  391. package/dist/features/store-extensions/schemas/listing-template-form.js +87 -0
  392. package/dist/features/store-extensions/schemas/moderation-review-form.d.ts +49 -0
  393. package/dist/features/store-extensions/schemas/moderation-review-form.js +101 -0
  394. package/dist/features/store-extensions/schemas/payout-method-form.d.ts +153 -0
  395. package/dist/features/store-extensions/schemas/payout-method-form.js +155 -0
  396. package/dist/features/store-extensions/schemas/report-create-form.d.ts +25 -0
  397. package/dist/features/store-extensions/schemas/report-create-form.js +79 -0
  398. package/dist/features/store-extensions/schemas/report-review-form.d.ts +47 -0
  399. package/dist/features/store-extensions/schemas/report-review-form.js +111 -0
  400. package/dist/features/store-extensions/schemas/shipping-config-form.d.ts +148 -0
  401. package/dist/features/store-extensions/schemas/shipping-config-form.js +104 -0
  402. package/dist/features/store-extensions/schemas/store-category-form.d.ts +54 -0
  403. package/dist/features/store-extensions/schemas/store-category-form.js +73 -0
  404. package/dist/features/stores/api/[storeSlug]/route.js +2 -25
  405. package/dist/features/stores/components/StoreAuctionsListing.js +15 -1
  406. package/dist/features/stores/components/StoreClassifiedsListing.js +12 -2
  407. package/dist/features/stores/components/StoreDetailLayoutView.js +24 -71
  408. package/dist/features/stores/components/StoreDigitalCodesListing.js +12 -2
  409. package/dist/features/stores/components/StoreLiveItemsListing.js +12 -2
  410. package/dist/features/stores/components/StorePreOrdersListing.js +12 -1
  411. package/dist/features/stores/components/StoreProductsListing.js +11 -1
  412. package/dist/features/stores/repository/store.repository.js +6 -0
  413. package/dist/features/stores/schemas/index.d.ts +6 -6
  414. package/dist/features/support/schemas/index.d.ts +4 -4
  415. package/dist/features/tester/actions/checklist-item-actions.d.ts +4 -4
  416. package/dist/features/tester/seed-data/offers-tester-seed-data.js +119 -3
  417. package/dist/features/tester/seed-data/products-tester-seed-data.js +131 -1
  418. package/dist/features/tester/seed-data/tester-checklist-seed-data.js +431 -1
  419. package/dist/features/wishlist/hooks/useWishlistWithGuest.d.ts +1 -1
  420. package/dist/index.d.ts +25 -12
  421. package/dist/index.js +26 -11
  422. package/dist/next/routing/route-map.d.ts +23 -3
  423. package/dist/next/routing/route-map.js +14 -2
  424. package/dist/providers/db-firebase/base.repository.d.ts +30 -0
  425. package/dist/providers/db-firebase/base.repository.js +50 -1
  426. package/dist/providers/db-firebase/index.d.ts +1 -1
  427. package/dist/providers/db-firebase/index.js +1 -1
  428. package/dist/providers/db-firebase/sieve.d.ts +25 -0
  429. package/dist/providers/db-firebase/sieve.js +52 -18
  430. package/dist/react/hooks/useUrlTable.js +10 -1
  431. package/dist/schemas/firestore-value.d.ts +8 -0
  432. package/dist/schemas/firestore-value.js +44 -0
  433. package/dist/schemas/index.d.ts +1 -1
  434. package/dist/schemas/index.js +1 -1
  435. package/dist/schemas/registry.d.ts +702 -69
  436. package/dist/schemas/registry.js +64 -1
  437. package/dist/seed/_helpers/category-forest.d.ts +2 -0
  438. package/dist/seed/_helpers/category-forest.js +309 -0
  439. package/dist/seed/_helpers/category-tree.d.ts +27 -0
  440. package/dist/seed/_helpers/category-tree.js +103 -0
  441. package/dist/seed/bids-seed-data.js +30 -0
  442. package/dist/seed/catalogue-seed-data.js +12 -12
  443. package/dist/seed/categories-seed-data.js +177 -162
  444. package/dist/seed/events-seed-data.js +61 -10
  445. package/dist/seed/homepage-sections-seed-data.js +5 -1
  446. package/dist/seed/offers-seed-data.js +244 -34
  447. package/dist/seed/orders-seed-data.js +336 -1
  448. package/dist/seed/products-art-seed-data.js +50 -12
  449. package/dist/seed/products-auctions-seed-data.js +138 -18
  450. package/dist/seed/products-classifieds-seed-data.js +80 -16
  451. package/dist/seed/products-digital-codes-seed-data.js +66 -18
  452. package/dist/seed/products-live-items-seed-data.js +64 -13
  453. package/dist/seed/products-preorders-seed-data.d.ts +0 -1
  454. package/dist/seed/products-preorders-seed-data.js +52 -13
  455. package/dist/seed/products-prize-draws-seed-data.js +63 -14
  456. package/dist/seed/products-standard-seed-data.js +99 -26
  457. package/dist/seed/products-stickers-seed-data.js +47 -12
  458. package/dist/seed/reviews-seed-data.js +6 -1
  459. package/dist/seed/site-settings-seed-data.d.ts +1 -38
  460. package/dist/seed/site-settings-seed-data.js +38 -76
  461. package/dist/seed/stores-seed-data.js +71 -1
  462. package/dist/seed/users-seed-data.js +15 -5
  463. package/dist/server-entry.d.ts +1 -2
  464. package/dist/server-entry.js +4 -3
  465. package/dist/server.d.ts +6 -3
  466. package/dist/server.js +13 -4
  467. package/dist/styles.css +78 -12
  468. package/dist/tailwind-utilities.css +1 -1
  469. package/dist/ui/components/Button.style.css +19 -4
  470. package/dist/ui/components/CollapsibleSection.d.ts +17 -1
  471. package/dist/ui/components/CollapsibleSection.js +6 -2
  472. package/dist/ui/components/FilterChipGroup.d.ts +25 -1
  473. package/dist/ui/components/FilterChipGroup.js +21 -4
  474. package/dist/ui/components/HandMode.style.css +47 -0
  475. package/dist/ui/components/Layout.d.ts +9 -2
  476. package/dist/ui/components/Layout.js +1 -1
  477. package/dist/ui/components/ListingLayout.js +8 -8
  478. package/dist/ui/components/ListingLayout.style.css +8 -7
  479. package/dist/ui/components/RecordDetailModal.d.ts +10 -1
  480. package/dist/ui/components/RecordDetailModal.js +2 -2
  481. package/dist/ui/components/StickyToolbar.d.ts +3 -1
  482. package/dist/ui/components/StickyToolbar.js +62 -20
  483. package/dist/ui/components/bottom-chrome-slot.d.ts +21 -0
  484. package/dist/ui/components/bottom-chrome-slot.js +29 -0
  485. package/dist/ui/components/index.style.css +3 -0
  486. package/dist/ui/forms/FormShell.d.ts +43 -13
  487. package/dist/ui/forms/FormShell.js +22 -11
  488. package/dist/ui/forms/index.d.ts +1 -1
  489. package/dist/ui/index.d.ts +1 -1
  490. package/package.json +2 -1
  491. package/scripts/node-esm-loader.mjs +65 -0
  492. package/scripts/seed-cli-loader.mjs +6 -49
  493. package/scripts/seed-cli.mjs +1 -1
@@ -1,14 +1,17 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { sieveFilter, sieveAnd, SIEVE_OP } from "@mohasinac/appkit";
3
3
  import { cache } from "react";
4
- import { storeRepository, productRepository, categoriesRepository, siteSettingsRepository, reviewRepository, couponsRepository } from "../../../repositories";
4
+ import { storeRepository, siteSettingsRepository, reviewRepository, couponsRepository } from "../../../repositories";
5
5
  import { ROUTES } from "../../../next";
6
6
  import { Container, Main, Section, Text } from "../../../ui";
7
7
  import { STORE_PAGE_TABS } from "../../products/constants/listing-tabs";
8
8
  import { isListingTypeEnabled, isCategoryTypeEnabled } from "../../../_internal/shared/listing-types/feature-flags";
9
+ import { pluginFor } from "../../../_internal/shared/listing-types/_registry";
10
+ import { listingTabCounts, } from "../../../_internal/server/features/products/listing-tab-counts";
9
11
  import { getSellerTrustStatus } from "../../scams/actions/scam-actions";
10
12
  import { StoreHeader } from "./StoreHeader";
11
13
  import { StoreNavTabs } from "./StoreNavTabs";
14
+ import { toStoreDetail } from "../../../_internal/server/features/stores/adapters";
12
15
  const STORE_LISTING_HREF = {
13
16
  products: (slug) => String(ROUTES.PUBLIC.STORE_PRODUCTS(slug)),
14
17
  auctions: (slug) => String(ROUTES.PUBLIC.STORE_AUCTIONS(slug)),
@@ -41,46 +44,14 @@ export async function StoreDetailLayoutView({ storeSlug, activeTab, children, sc
41
44
  ? getSellerTrustStatus(storeId).catch(() => undefined)
42
45
  : Promise.resolve(undefined),
43
46
  ]);
44
- const [productsCount, auctionsCount, preOrdersCount, prizeDrawsCount, bundlesCount, classifiedsCount, digitalCodesCount, liveCount, artStickersCount, couponsCount, reviewsCount] = storeId
47
+ // One derived batch instead of nine copy-pasted per-type queries. The tabs
48
+ // themselves say which listing types to count (including the combined
49
+ // `art|stickers` OR-group), so a tenth type is counted automatically — the
50
+ // hand-written `TAB_LISTING_TYPE` map this replaces was unguarded by any
51
+ // audit and already omitted art/stickers (Root Cause #61).
52
+ const [listingCounts, couponsCount, reviewsCount] = storeId
45
53
  ? await Promise.all([
46
- productRepository
47
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "standard")), page: 1, pageSize: 1 })
48
- .then((r) => r.total)
49
- .catch(() => 0),
50
- productRepository
51
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "auction")), page: 1, pageSize: 1 })
52
- .then((r) => r.total)
53
- .catch(() => 0),
54
- productRepository
55
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "pre-order")), page: 1, pageSize: 1 })
56
- .then((r) => r.total)
57
- .catch(() => 0),
58
- productRepository
59
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "prize-draw")), page: 1, pageSize: 1 })
60
- .then((r) => r.total)
61
- .catch(() => 0),
62
- // SB-UNI-D — bundles live on categories with categoryType:"bundle"
63
- // + createdByStoreId scoping.
64
- categoriesRepository
65
- .listByType("bundle", { activeOnly: true, limit: 100 })
66
- .then((rows) => rows.filter((c) => c.createdByStoreId === storeId).length)
67
- .catch(() => 0),
68
- productRepository
69
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "classified")), page: 1, pageSize: 1 })
70
- .then((r) => r.total)
71
- .catch(() => 0),
72
- productRepository
73
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "digital-code")), page: 1, pageSize: 1 })
74
- .then((r) => r.total)
75
- .catch(() => 0),
76
- productRepository
77
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "live")), page: 1, pageSize: 1 })
78
- .then((r) => r.total)
79
- .catch(() => 0),
80
- productRepository
81
- .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("status", SIEVE_OP.EQ, "published"), sieveFilter("listingType", SIEVE_OP.EQ, "art|stickers")), page: 1, pageSize: 1 })
82
- .then((r) => r.total)
83
- .catch(() => 0),
54
+ listingTabCounts(STORE_PAGE_TABS, { storeId }),
84
55
  couponsRepository
85
56
  .list({ filters: sieveAnd(sieveFilter("storeId", SIEVE_OP.EQ, storeId), sieveFilter("validity.isActive", SIEVE_OP.EQ, "true")), page: 1, pageSize: 1 })
86
57
  .then((r) => r.total)
@@ -90,46 +61,28 @@ export async function StoreDetailLayoutView({ storeSlug, activeTab, children, sc
90
61
  .then((r) => r.total)
91
62
  .catch(() => 0),
92
63
  ])
93
- : [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
94
- const listingCounts = {
95
- products: productsCount,
96
- auctions: auctionsCount,
97
- "pre-orders": preOrdersCount,
98
- "prize-draws": prizeDrawsCount,
99
- bundles: bundlesCount,
100
- classifieds: classifiedsCount,
101
- "digital-codes": digitalCodesCount,
102
- live: liveCount,
103
- art: artStickersCount,
104
- };
105
- const TAB_LISTING_TYPE = {
106
- products: "standard",
107
- auctions: "auction",
108
- "pre-orders": "pre-order",
109
- "prize-draws": "prize-draw",
110
- classifieds: "classified",
111
- "digital-codes": "digital-code",
112
- live: "live",
113
- };
64
+ : [{}, 0, 0];
114
65
  const visibleStoreTabs = STORE_PAGE_TABS.filter((tab) => {
115
66
  if (tab.id === "bundles") {
116
67
  if (!isCategoryTypeEnabled("bundle", settings))
117
68
  return false;
118
- return listingCounts[tab.id] > 0;
119
69
  }
120
- // Combined tab — visible if either underlying listing type is enabled.
121
- if (tab.id === "art") {
70
+ else if (tab.id === pluginFor("art").tabSlug) {
71
+ // Combined tab — visible if either underlying listing type is enabled.
122
72
  if (!(isListingTypeEnabled("art", settings) || isListingTypeEnabled("stickers", settings)))
123
73
  return false;
124
- return listingCounts[tab.id] > 0;
125
74
  }
126
- const lt = TAB_LISTING_TYPE[tab.id];
127
- if (lt && !isListingTypeEnabled(lt, settings))
128
- return false;
75
+ else if (tab.listingType) {
76
+ if (!isListingTypeEnabled(tab.listingType, settings))
77
+ return false;
78
+ }
129
79
  // A store with zero items of a given listing type shouldn't offer a tab
130
80
  // that leads to an empty page — matches the "hide empty tab" rule below
131
- // for coupons/reviews.
132
- return listingCounts[tab.id] > 0;
81
+ // for coupons/reviews. `undefined` means the count query FAILED, not zero,
82
+ // so the tab stays visible rather than hiding real stock behind a
83
+ // swallowed error (Root Cause #59) — this used to be `.catch(() => 0)`.
84
+ const count = listingCounts[tab.id];
85
+ return count === undefined || count > 0;
133
86
  });
134
87
  const dropdownTabs = visibleStoreTabs.map((tab) => ({
135
88
  value: tab.id,
@@ -145,5 +98,5 @@ export async function StoreDetailLayoutView({ storeSlug, activeTab, children, sc
145
98
  : []),
146
99
  { value: "about", label: "About", href: String(ROUTES.PUBLIC.STORE_ABOUT(storeSlug)) },
147
100
  ];
148
- return (_jsxs(Main, { children: [_jsx(StoreHeader, { store: store, trust: trust }), _jsxs(Container, { size: "xl", className: "mt-6", children: [_jsx(StoreNavTabs, { dropdownTabs: dropdownTabs, dropdownPlaceholder: "Browse listings", tabs: tabs, activeValue: activeTab }), _jsx(Section, { padding: "t-lg", children: children })] })] }));
101
+ return (_jsxs(Main, { children: [_jsx(StoreHeader, { store: toStoreDetail(store), trust: trust }), _jsxs(Container, { size: "xl", className: "mt-6", children: [_jsx(StoreNavTabs, { dropdownTabs: dropdownTabs, dropdownPlaceholder: "Browse listings", tabs: tabs, activeValue: activeTab }), _jsx(Section, { padding: "t-lg", children: children })] })] }));
149
102
  }
@@ -8,9 +8,12 @@ import { Div, FilterDrawer, ListingToolbar, Pagination, Row, Text, StickyToolbar
8
8
  import { DigitalCodeFilters } from "../../digital-codes/components/DigitalCodeFilters";
9
9
  import { InteractiveProductCard } from "../../products/components/InteractiveProductCard";
10
10
  import { PRODUCT_FIELDS } from "../../../constants/field-names";
11
- import { TABLE_KEYS } from "../../../constants/table-keys";
12
11
  import { sortBy } from "../../../constants/sort";
13
12
  import { ROUTES } from "../../../next";
13
+ import { AvailabilityTabs } from "../../products/components/AvailabilityTabs";
14
+ import { AVAILABILITY_VALUES } from "../../../constants/field-names";
15
+ import { TABLE_KEYS } from "../../../constants/table-keys";
16
+ const STORE_DIGITAL_CODE_TYPES = ["digital-code"];
14
17
  const DEFAULT_SORT = sortBy(PRODUCT_FIELDS.CREATED_AT);
15
18
  const SORT_OPTIONS = [
16
19
  { value: sortBy(PRODUCT_FIELDS.CREATED_AT), label: "Newest First" },
@@ -28,6 +31,12 @@ export function StoreDigitalCodesListing({ storeId, initialData }) {
28
31
  const applyFilters = useCallback(() => { onFilterApply(); setFilterOpen(false); }, [onFilterApply]);
29
32
  const resetAll = useCallback(() => { onResetAll({ q: "", sort: "" }); setSearchInput(""); }, [onResetAll]);
30
33
  const hasActiveState = !!table.get("q") || table.get("sort") !== DEFAULT_SORT || filterActiveCount > 0;
34
+ // Absent means "available" — the same default `listStoreProducts`
35
+ // resolves server-side. These six store tabs sent NO availability
36
+ // param at all until 2026-08-24, while their SSR fetch did apply one,
37
+ // so any client refetch silently widened the list (Root Cause #30).
38
+ const availability = table.get(TABLE_KEYS.AVAILABILITY) ||
39
+ AVAILABILITY_VALUES.AVAILABLE;
31
40
  const params = {
32
41
  q: table.get("q") || undefined,
33
42
  minPrice: table.get(TABLE_KEYS.MIN_PRICE) ? Number(table.get(TABLE_KEYS.MIN_PRICE)) : undefined,
@@ -42,10 +51,11 @@ export function StoreDigitalCodesListing({ storeId, initialData }) {
42
51
  typeFacets: {
43
52
  [TABLE_KEYS.DELIVERY_METHOD]: table.get(TABLE_KEYS.DELIVERY_METHOD),
44
53
  },
54
+ availability,
45
55
  };
46
56
  const { products, totalPages, page, isLoading } = useProducts(params, { initialData });
47
57
  const gridClass = "grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-[var(--appkit-space-4)]";
48
- return (_jsxs(Div, { className: "min-h-[200px]", children: [_jsx(ListingToolbar, { filterCount: filterActiveCount, onFiltersClick: openFilters, searchValue: searchInput, searchPlaceholder: "Search digital codes\u2026", onSearchChange: setSearchInput, onSearchCommit: () => table.set("q", searchInput.trim()), sortValue: table.get("sort") || DEFAULT_SORT, sortOptions: SORT_OPTIONS, onSortChange: (v) => table.set("sort", v), onResetAll: resetAll, hasActiveState: hasActiveState }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: _jsx(Div, { className: gridClass, children: isLoading
58
+ return (_jsxs(Div, { className: "min-h-[200px]", children: [_jsx(ListingToolbar, { filterCount: filterActiveCount, onFiltersClick: openFilters, searchValue: searchInput, searchPlaceholder: "Search digital codes\u2026", onSearchChange: setSearchInput, onSearchCommit: () => table.set("q", searchInput.trim()), sortValue: table.get("sort") || DEFAULT_SORT, sortOptions: SORT_OPTIONS, onSortChange: (v) => table.set("sort", v), onResetAll: resetAll, hasActiveState: hasActiveState }), _jsx(Div, { padding: "y-sm", children: _jsx(AvailabilityTabs, { types: STORE_DIGITAL_CODE_TYPES }) }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: _jsx(Div, { className: gridClass, children: isLoading
49
59
  ? Array.from({ length: 8 }).map((_, i) => _jsx(Div, { surface: "muted", rounded: "xl", className: "aspect-square animate-pulse" }, i))
50
60
  : products.length === 0
51
61
  ? _jsx(Div, { paddingY: "y-4xl", className: "col-span-full text-left", children: _jsx(Text, { color: "muted", children: "No digital codes in this store yet." }) })
@@ -8,9 +8,12 @@ import { Div, FilterDrawer, ListingToolbar, Pagination, Row, Text, StickyToolbar
8
8
  import { LiveItemFilters } from "../../live/components/LiveItemFilters";
9
9
  import { InteractiveProductCard } from "../../products/components/InteractiveProductCard";
10
10
  import { PRODUCT_FIELDS } from "../../../constants/field-names";
11
- import { TABLE_KEYS } from "../../../constants/table-keys";
12
11
  import { sortBy } from "../../../constants/sort";
13
12
  import { ROUTES } from "../../../next";
13
+ import { AvailabilityTabs } from "../../products/components/AvailabilityTabs";
14
+ import { AVAILABILITY_VALUES } from "../../../constants/field-names";
15
+ import { TABLE_KEYS } from "../../../constants/table-keys";
16
+ const STORE_LIVE_TYPES = ["live"];
14
17
  const DEFAULT_SORT = sortBy(PRODUCT_FIELDS.CREATED_AT);
15
18
  const SORT_OPTIONS = [
16
19
  { value: sortBy(PRODUCT_FIELDS.CREATED_AT), label: "Newest First" },
@@ -28,6 +31,12 @@ export function StoreLiveItemsListing({ storeId, initialData }) {
28
31
  const applyFilters = useCallback(() => { onFilterApply(); setFilterOpen(false); }, [onFilterApply]);
29
32
  const resetAll = useCallback(() => { onResetAll({ q: "", sort: "" }); setSearchInput(""); }, [onResetAll]);
30
33
  const hasActiveState = !!table.get("q") || table.get("sort") !== DEFAULT_SORT || filterActiveCount > 0;
34
+ // Absent means "available" — the same default `listStoreProducts`
35
+ // resolves server-side. These six store tabs sent NO availability
36
+ // param at all until 2026-08-24, while their SSR fetch did apply one,
37
+ // so any client refetch silently widened the list (Root Cause #30).
38
+ const availability = table.get(TABLE_KEYS.AVAILABILITY) ||
39
+ AVAILABILITY_VALUES.AVAILABLE;
31
40
  const params = {
32
41
  q: table.get("q") || undefined,
33
42
  minPrice: table.get(TABLE_KEYS.MIN_PRICE) ? Number(table.get(TABLE_KEYS.MIN_PRICE)) : undefined,
@@ -44,10 +53,11 @@ export function StoreLiveItemsListing({ storeId, initialData }) {
44
53
  [TABLE_KEYS.LIVE_SEX]: table.get(TABLE_KEYS.LIVE_SEX),
45
54
  [TABLE_KEYS.JURISDICTION]: table.get(TABLE_KEYS.JURISDICTION),
46
55
  },
56
+ availability,
47
57
  };
48
58
  const { products, totalPages, page, isLoading } = useProducts(params, { initialData });
49
59
  const gridClass = "grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-[var(--appkit-space-4)]";
50
- return (_jsxs(Div, { className: "min-h-[200px]", children: [_jsx(ListingToolbar, { filterCount: filterActiveCount, onFiltersClick: openFilters, searchValue: searchInput, searchPlaceholder: "Search live animals & plants\u2026", onSearchChange: setSearchInput, onSearchCommit: () => table.set("q", searchInput.trim()), sortValue: table.get("sort") || DEFAULT_SORT, sortOptions: SORT_OPTIONS, onSortChange: (v) => table.set("sort", v), onResetAll: resetAll, hasActiveState: hasActiveState }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: _jsx(Div, { className: gridClass, children: isLoading
60
+ return (_jsxs(Div, { className: "min-h-[200px]", children: [_jsx(ListingToolbar, { filterCount: filterActiveCount, onFiltersClick: openFilters, searchValue: searchInput, searchPlaceholder: "Search live animals & plants\u2026", onSearchChange: setSearchInput, onSearchCommit: () => table.set("q", searchInput.trim()), sortValue: table.get("sort") || DEFAULT_SORT, sortOptions: SORT_OPTIONS, onSortChange: (v) => table.set("sort", v), onResetAll: resetAll, hasActiveState: hasActiveState }), _jsx(Div, { padding: "y-sm", children: _jsx(AvailabilityTabs, { types: STORE_LIVE_TYPES }) }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: _jsx(Div, { className: gridClass, children: isLoading
51
61
  ? Array.from({ length: 8 }).map((_, i) => _jsx(Div, { surface: "muted", rounded: "xl", className: "aspect-square animate-pulse" }, i))
52
62
  : products.length === 0
53
63
  ? _jsx(Div, { paddingY: "y-4xl", className: "col-span-full text-left", children: _jsx(Text, { color: "muted", children: "No live items in this store yet." }) })
@@ -9,6 +9,10 @@ import { MarketplacePreorderCard } from "../../pre-orders/components/Marketplace
9
9
  import { ProductFilters } from "../../products/components/ProductFilters";
10
10
  import { ROUTES } from "../../../next";
11
11
  import { PREORDER_PUBLIC_SORT_OPTIONS } from "../../products/constants/sieve";
12
+ import { AvailabilityTabs } from "../../products/components/AvailabilityTabs";
13
+ import { AVAILABILITY_VALUES } from "../../../constants/field-names";
14
+ import { TABLE_KEYS } from "../../../constants/table-keys";
15
+ const STORE_PRE_ORDER_TYPES = ["pre-order"];
12
16
  const __P = {
13
17
  p3: "p-[var(--appkit-space-3)]",
14
18
  };
@@ -38,6 +42,12 @@ export function StorePreOrdersListing({ storeId, initialData }) {
38
42
  const hasActiveState = !!table.get("q") ||
39
43
  table.get("sort") !== DEFAULT_SORT ||
40
44
  filterActiveCount > 0;
45
+ // Absent means "available" — the same default `listStoreProducts`
46
+ // resolves server-side. These six store tabs sent NO availability
47
+ // param at all until 2026-08-24, while their SSR fetch did apply one,
48
+ // so any client refetch silently widened the list (Root Cause #30).
49
+ const availability = table.get(TABLE_KEYS.AVAILABILITY) ||
50
+ AVAILABILITY_VALUES.AVAILABLE;
41
51
  const params = {
42
52
  q: table.get("q") || undefined,
43
53
  minPrice: table.get("minPrice") ? Number(table.get("minPrice")) : undefined,
@@ -47,6 +57,7 @@ export function StorePreOrdersListing({ storeId, initialData }) {
47
57
  perPage: table.getNumber("pageSize", 24),
48
58
  storeId: storeId || undefined,
49
59
  listingType: "pre-order",
60
+ availability,
50
61
  };
51
62
  const { products: preOrders, totalPages, page, isLoading } = useProducts(params, { initialData });
52
63
  const commitSearch = useCallback(() => {
@@ -61,5 +72,5 @@ export function StorePreOrdersListing({ storeId, initialData }) {
61
72
  return;
62
73
  setView(v);
63
74
  table.set("view", v);
64
- }, onResetAll: resetAll, hasActiveState: hasActiveState }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: isLoading ? (_jsx(Div, { className: gridClass, children: Array.from({ length: 8 }).map((_, i) => (_jsxs(Div, { className: "overflow-hidden animate-pulse", border: "subtle", rounded: "xl", children: [_jsx(Div, { className: "aspect-square", surface: "subtle" }), _jsxs(Stack, { className: `${__P.p3}`, gap: "sm", children: [_jsx(Div, { className: "h-3 w-3/4", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-3 w-1/2", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-8", surface: "subtle", rounded: "default" })] })] }, i))) })) : preOrders.length === 0 ? (_jsx(Text, { paddingY: "3xl", color: "muted", size: "sm", align: "start", children: "This store has no pre-orders yet." })) : view === "list" ? (_jsx(Stack, { className: "divide-y divide-zinc-100 divide-[var(--appkit-color-border-subtle)]", border: "subtle", rounded: "xl", children: preOrders.map((product) => (_jsx(MarketplacePreorderCard, { product: product, variant: "list", hrefBuilder: (p) => String(ROUTES.PUBLIC.PRE_ORDER_DETAIL(p.id)) }, product.id))) })) : (_jsx(Div, { className: gridClass, children: preOrders.map((product) => (_jsx(MarketplacePreorderCard, { product: product, variant: "grid", hrefBuilder: (p) => String(ROUTES.PUBLIC.PRE_ORDER_DETAIL(p.id)) }, product.id))) })) }), _jsx(FilterDrawer, { open: filterOpen, onOpen: openFilters, onClose: () => setFilterOpen(false), onApply: applyFilters, onReset: onFilterClear, activeCount: filterActiveCount, hideTrigger: true, children: _jsx(ProductFilters, { table: pendingTable, currencyPrefix: "\u20B9" }) })] }));
75
+ }, onResetAll: resetAll, hasActiveState: hasActiveState }), _jsx(Div, { padding: "y-sm", children: _jsx(AvailabilityTabs, { types: STORE_PRE_ORDER_TYPES }) }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: isLoading ? (_jsx(Div, { className: gridClass, children: Array.from({ length: 8 }).map((_, i) => (_jsxs(Div, { className: "overflow-hidden animate-pulse", border: "subtle", rounded: "xl", children: [_jsx(Div, { className: "aspect-square", surface: "subtle" }), _jsxs(Stack, { className: `${__P.p3}`, gap: "sm", children: [_jsx(Div, { className: "h-3 w-3/4", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-3 w-1/2", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-8", surface: "subtle", rounded: "default" })] })] }, i))) })) : preOrders.length === 0 ? (_jsx(Text, { paddingY: "3xl", color: "muted", size: "sm", align: "start", children: "This store has no pre-orders yet." })) : view === "list" ? (_jsx(Stack, { className: "divide-y divide-zinc-100 divide-[var(--appkit-color-border-subtle)]", border: "subtle", rounded: "xl", children: preOrders.map((product) => (_jsx(MarketplacePreorderCard, { product: product, variant: "list", hrefBuilder: (p) => String(ROUTES.PUBLIC.PRE_ORDER_DETAIL(p.id)) }, product.id))) })) : (_jsx(Div, { className: gridClass, children: preOrders.map((product) => (_jsx(MarketplacePreorderCard, { product: product, variant: "grid", hrefBuilder: (p) => String(ROUTES.PUBLIC.PRE_ORDER_DETAIL(p.id)) }, product.id))) })) }), _jsx(FilterDrawer, { open: filterOpen, onOpen: openFilters, onClose: () => setFilterOpen(false), onApply: applyFilters, onReset: onFilterClear, activeCount: filterActiveCount, hideTrigger: true, children: _jsx(ProductFilters, { table: pendingTable, currencyPrefix: "\u20B9" }) })] }));
65
76
  }
@@ -13,6 +13,9 @@ import { ProductFilters, PRODUCT_PUBLIC_SORT_OPTIONS } from "../../products/comp
13
13
  import { useGuestCart } from "../../cart/hooks/useGuestCart";
14
14
  import { useGuestWishlist } from "../../wishlist/hooks/useGuestWishlist";
15
15
  import { pushCartOp, pushWishlistOp } from "../../cart/utils/pending-ops";
16
+ import { AvailabilityTabs } from "../../products/components/AvailabilityTabs";
17
+ import { AVAILABILITY_VALUES } from "../../../constants/field-names";
18
+ import { TABLE_KEYS } from "../../../constants/table-keys";
16
19
  const __P = {
17
20
  p3: "p-[var(--appkit-space-3)]",
18
21
  };
@@ -43,6 +46,12 @@ export function StoreProductsListing({ storeId, listingTypes = ["standard"], ini
43
46
  const hasActiveState = !!table.get("q") ||
44
47
  table.get("sort") !== "-createdAt" ||
45
48
  filterActiveCount > 0;
49
+ // Absent means "available" — the same default `listStoreProducts`
50
+ // resolves server-side. These six store tabs sent NO availability
51
+ // param at all until 2026-08-24, while their SSR fetch did apply one,
52
+ // so any client refetch silently widened the list (Root Cause #30).
53
+ const availability = table.get(TABLE_KEYS.AVAILABILITY) ||
54
+ AVAILABILITY_VALUES.AVAILABLE;
46
55
  const params = {
47
56
  q: table.get("q") || undefined,
48
57
  condition: table.get("condition") || undefined,
@@ -55,6 +64,7 @@ export function StoreProductsListing({ storeId, listingTypes = ["standard"], ini
55
64
  storeId: storeId || undefined,
56
65
  // Pipe-joined OR-group when the tab spans several types.
57
66
  listingType: listingTypes.join("|"),
67
+ availability,
58
68
  };
59
69
  const { products, totalPages, page, isLoading } = useProducts(params, { initialData });
60
70
  const commitSearch = useCallback(() => {
@@ -94,5 +104,5 @@ export function StoreProductsListing({ storeId, listingTypes = ["standard"], ini
94
104
  }, [localCart, showToast]);
95
105
  return (_jsxs(Div, { className: "min-h-[200px]", children: [_jsx(ListingToolbar, { filterCount: filterActiveCount, onFiltersClick: openFilters, searchValue: searchInput, searchPlaceholder: "Search store products...", onSearchChange: setSearchInput, onSearchCommit: commitSearch, sortValue: table.get("sort") || "-createdAt", sortOptions: PRODUCT_PUBLIC_SORT_OPTIONS, onSortChange: (v) => {
96
106
  table.set("sort", v);
97
- }, view: view === "card" ? "grid" : "list", onViewChange: (v) => handleViewToggle(v === "grid" ? "card" : "list"), onResetAll: resetAll, hasActiveState: hasActiveState }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: isLoading ? (_jsx(Div, { layout: "grid", gap: "6", className: "grid-cols-2 sm:grid-cols-3 lg:grid-cols-4", children: Array.from({ length: 8 }).map((_, i) => (_jsxs(Div, { className: "overflow-hidden animate-pulse", border: "subtle", rounded: "xl", children: [_jsx(Div, { className: "aspect-square", surface: "subtle" }), _jsxs(Stack, { className: `${__P.p3}`, gap: "sm", children: [_jsx(Div, { className: "h-3 w-3/4", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-3 w-1/2", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-4 w-1/3", surface: "subtle", rounded: "default" })] })] }, i))) })) : (_jsx(ProductGrid, { products: products, getProductHref: (p) => String(ROUTES.PUBLIC.PRODUCT_DETAIL(p.slug || p.id)), view: view, emptyLabel: "This store has no products yet.", onWishlistToggle: handleWishlistToggle, wishlistedIds: wishlistedIds, onAddToCart: handleAddToCart })) }), _jsx(FilterDrawer, { open: filterOpen, onOpen: openFilters, onClose: () => setFilterOpen(false), onApply: applyFilters, onReset: onFilterClear, activeCount: filterActiveCount, hideTrigger: true, children: _jsx(ProductFilters, { table: pendingTable, currencyPrefix: "\u20B9" }) }), _jsx(LoginRequiredModal, { isOpen: modalOpen, onClose: closeModal, message: modalMessage })] }));
107
+ }, view: view === "card" ? "grid" : "list", onViewChange: (v) => handleViewToggle(v === "grid" ? "card" : "list"), onResetAll: resetAll, hasActiveState: hasActiveState }), _jsx(Div, { padding: "y-sm", children: _jsx(AvailabilityTabs, { types: listingTypes }) }), totalPages > 1 && (_jsx(StickyToolbar, { offset: "header+pagination", tone: "translucent", border: true, padding: "toolbar", children: _jsx(Row, { justify: "center", children: _jsx(Pagination, { currentPage: page, totalPages: totalPages, onPageChange: (p) => table.setPage(p) }) }) })), _jsx(Div, { padding: "y-lg", children: isLoading ? (_jsx(Div, { layout: "grid", gap: "6", className: "grid-cols-2 sm:grid-cols-3 lg:grid-cols-4", children: Array.from({ length: 8 }).map((_, i) => (_jsxs(Div, { className: "overflow-hidden animate-pulse", border: "subtle", rounded: "xl", children: [_jsx(Div, { className: "aspect-square", surface: "subtle" }), _jsxs(Stack, { className: `${__P.p3}`, gap: "sm", children: [_jsx(Div, { className: "h-3 w-3/4", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-3 w-1/2", surface: "subtle", rounded: "default" }), _jsx(Div, { className: "h-4 w-1/3", surface: "subtle", rounded: "default" })] })] }, i))) })) : (_jsx(ProductGrid, { products: products, getProductHref: (p) => String(ROUTES.PUBLIC.PRODUCT_DETAIL(p.slug || p.id)), view: view, emptyLabel: "This store has no products yet.", onWishlistToggle: handleWishlistToggle, wishlistedIds: wishlistedIds, onAddToCart: handleAddToCart })) }), _jsx(FilterDrawer, { open: filterOpen, onOpen: openFilters, onClose: () => setFilterOpen(false), onApply: applyFilters, onReset: onFilterClear, activeCount: filterActiveCount, hideTrigger: true, children: _jsx(ProductFilters, { table: pendingTable, currencyPrefix: "\u20B9" }) }), _jsx(LoginRequiredModal, { isOpen: modalOpen, onClose: closeModal, message: modalMessage })] }));
98
108
  }
@@ -118,6 +118,12 @@ export class StoreRepository extends BaseRepository {
118
118
  [STORE_FIELDS.STORE_CATEGORY]: { canFilter: true, canSort: false },
119
119
  [STORE_FIELDS.STATUS]: { canFilter: true, canSort: false },
120
120
  [STORE_FIELDS.IS_PUBLIC]: { canFilter: true, canSort: false },
121
+ // The public /stores toolbar has always emitted `isFeatured==true` for its
122
+ // "Featured" toggle, and the API allowlist has always accepted it — but it
123
+ // was absent from this map, so sievejs (`throwExceptions: false`) dropped
124
+ // the clause and the toggle did nothing at all. Root Cause #62's
125
+ // EMITTED_BUT_UNFILTERABLE, live in production.
126
+ [STORE_FIELDS.IS_FEATURED]: { canFilter: true, canSort: false },
121
127
  [STORE_FIELDS.CREATED_AT]: { canFilter: false, canSort: true },
122
128
  "stats.itemsSold": { canFilter: false, canSort: true },
123
129
  "stats.averageRating": { canFilter: false, canSort: true },
@@ -410,13 +410,12 @@ export declare const storeFirestoreSchema: z.ZodObject<{
410
410
  updatedAt: string | Date | z.objectOutputType<{
411
411
  toDate: z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodDate>;
412
412
  }, z.ZodTypeAny, "passthrough">;
413
- storeName: string;
414
413
  ownerId: string;
414
+ storeName: string;
415
415
  storeSlug: string;
416
416
  isPublic: boolean;
417
417
  location?: string | undefined;
418
418
  returnPolicy?: string | undefined;
419
- isFeatured?: boolean | undefined;
420
419
  stats?: {
421
420
  itemsSold: number;
422
421
  totalProducts: number;
@@ -427,6 +426,7 @@ export declare const storeFirestoreSchema: z.ZodObject<{
427
426
  storeDescription?: string | undefined;
428
427
  storeLogoURL?: string | undefined;
429
428
  storeBannerURL?: string | undefined;
429
+ isFeatured?: boolean | undefined;
430
430
  capabilities?: string[] | undefined;
431
431
  shippingConfig?: {
432
432
  providers: {
@@ -495,13 +495,12 @@ export declare const storeFirestoreSchema: z.ZodObject<{
495
495
  updatedAt: string | Date | z.objectInputType<{
496
496
  toDate: z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodDate>;
497
497
  }, z.ZodTypeAny, "passthrough">;
498
- storeName: string;
499
498
  ownerId: string;
499
+ storeName: string;
500
500
  storeSlug: string;
501
501
  isPublic: boolean;
502
502
  location?: string | undefined;
503
503
  returnPolicy?: string | undefined;
504
- isFeatured?: boolean | undefined;
505
504
  stats?: {
506
505
  itemsSold: number;
507
506
  totalProducts: number;
@@ -512,6 +511,7 @@ export declare const storeFirestoreSchema: z.ZodObject<{
512
511
  storeDescription?: string | undefined;
513
512
  storeLogoURL?: string | undefined;
514
513
  storeBannerURL?: string | undefined;
514
+ isFeatured?: boolean | undefined;
515
515
  capabilities?: string[] | undefined;
516
516
  shippingConfig?: {
517
517
  providers: {
@@ -607,8 +607,8 @@ export declare const storeListItemSchema: z.ZodObject<{
607
607
  }, "strip", z.ZodTypeAny, {
608
608
  status: string;
609
609
  id: string;
610
- storeName: string;
611
610
  ownerId: string;
611
+ storeName: string;
612
612
  storeSlug: string;
613
613
  isPublic: boolean;
614
614
  createdAt?: string | undefined;
@@ -623,8 +623,8 @@ export declare const storeListItemSchema: z.ZodObject<{
623
623
  }, {
624
624
  status: string;
625
625
  id: string;
626
- storeName: string;
627
626
  ownerId: string;
627
+ storeName: string;
628
628
  storeSlug: string;
629
629
  isPublic: boolean;
630
630
  createdAt?: string | undefined;
@@ -158,12 +158,12 @@ export declare const supportTicketFirestoreSchema: z.ZodObject<{
158
158
  toDate: z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodDate>;
159
159
  }, z.ZodTypeAny, "passthrough">;
160
160
  userId: string;
161
- category: "general" | "account" | "order_issue" | "billing_payment" | "listing_dispute" | "scam_report" | "refund_request" | "auction_dispute" | "store_change_request" | "order_modification_request" | "unban_request";
162
161
  description: string;
163
- priority: "normal" | "high" | "low" | "urgent";
162
+ category: "general" | "account" | "order_issue" | "billing_payment" | "listing_dispute" | "scam_report" | "refund_request" | "auction_dispute" | "store_change_request" | "order_modification_request" | "unban_request";
164
163
  userEmail: string;
165
164
  userDisplayName: string;
166
165
  subject: string;
166
+ priority: "normal" | "high" | "low" | "urgent";
167
167
  messages: {
168
168
  id: string;
169
169
  body: string;
@@ -201,12 +201,12 @@ export declare const supportTicketFirestoreSchema: z.ZodObject<{
201
201
  toDate: z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodDate>;
202
202
  }, z.ZodTypeAny, "passthrough">;
203
203
  userId: string;
204
- category: "general" | "account" | "order_issue" | "billing_payment" | "listing_dispute" | "scam_report" | "refund_request" | "auction_dispute" | "store_change_request" | "order_modification_request" | "unban_request";
205
204
  description: string;
206
- priority: "normal" | "high" | "low" | "urgent";
205
+ category: "general" | "account" | "order_issue" | "billing_payment" | "listing_dispute" | "scam_report" | "refund_request" | "auction_dispute" | "store_change_request" | "order_modification_request" | "unban_request";
207
206
  userEmail: string;
208
207
  userDisplayName: string;
209
208
  subject: string;
209
+ priority: "normal" | "high" | "low" | "urgent";
210
210
  messages: {
211
211
  id: string;
212
212
  body: string;
@@ -14,8 +14,8 @@ export declare const checklistItemCreateSchema: z.ZodObject<{
14
14
  adminOnly: z.ZodDefault<z.ZodBoolean>;
15
15
  }, "strip", z.ZodTypeAny, {
16
16
  label: string;
17
- order: number;
18
17
  isActive: boolean;
18
+ order: number;
19
19
  groupKey: string;
20
20
  pageKey: string;
21
21
  phase: number;
@@ -32,8 +32,8 @@ export declare const checklistItemCreateSchema: z.ZodObject<{
32
32
  pageLabel: string;
33
33
  href?: string | undefined;
34
34
  description?: string | undefined;
35
- order?: number | undefined;
36
35
  isActive?: boolean | undefined;
36
+ order?: number | undefined;
37
37
  phase?: number | undefined;
38
38
  adminOnly?: boolean | undefined;
39
39
  }>;
@@ -53,8 +53,8 @@ export declare const checklistItemUpdateSchema: z.ZodObject<{
53
53
  label?: string | undefined;
54
54
  href?: string | undefined;
55
55
  description?: string | undefined;
56
- order?: number | undefined;
57
56
  isActive?: boolean | undefined;
57
+ order?: number | undefined;
58
58
  groupKey?: string | undefined;
59
59
  pageKey?: string | undefined;
60
60
  phase?: number | undefined;
@@ -65,8 +65,8 @@ export declare const checklistItemUpdateSchema: z.ZodObject<{
65
65
  label?: string | undefined;
66
66
  href?: string | undefined;
67
67
  description?: string | undefined;
68
- order?: number | undefined;
69
68
  isActive?: boolean | undefined;
69
+ order?: number | undefined;
70
70
  groupKey?: string | undefined;
71
71
  pageKey?: string | undefined;
72
72
  phase?: number | undefined;
@@ -39,11 +39,15 @@ export const offersTesterSeedData = [
39
39
  buyerUid: "user-tester-qa",
40
40
  buyerName: "QA Tester",
41
41
  buyerEmail: "tester@letitrip.in",
42
- listedPrice: 1899,
43
- offerAmount: 1450,
42
+ // Realigned 2026-08-24: this carried listedPrice 1899 / offer 1450 against
43
+ // a product that costs ₹999 — an offer ABOVE the listing price, which
44
+ // `makeOffer` would reject outright. Same stale-snapshot drift the main
45
+ // offers seed had.
46
+ listedPrice: 999,
47
+ offerAmount: 780,
44
48
  // The agreed price. Checkout MUST bill this, not `listedPrice` — that
45
49
  // divergence is exactly what the paired checklist case checks.
46
- lockedPrice: 1450,
50
+ lockedPrice: 780,
47
51
  currency: "INR",
48
52
  status: OfferStatusValues.ACCEPTED,
49
53
  buyerNote: "Sandbox offer — already accepted so testers can drive checkout.",
@@ -58,4 +62,116 @@ export const offersTesterSeedData = [
58
62
  isTestData: true,
59
63
  testDataExpiresAt: testDataExpiresAt(),
60
64
  },
65
+ /**
66
+ * COUNTERED. The buyer-accepts-a-counter path had no fixture at all, so
67
+ * `acceptCounterOffer` was unreachable for a tester working solo.
68
+ */
69
+ {
70
+ id: "offer-tester-sandbox-countered",
71
+ productId: "product-beyblade-metal-storm-pegasus",
72
+ productTitle: "Beyblade Metal Storm Pegasus",
73
+ productSlug: "product-beyblade-metal-storm-pegasus",
74
+ storeId: "store-beyblade-arena",
75
+ storeName: "Beyblade Arena",
76
+ buyerUid: "user-tester-qa",
77
+ buyerName: "QA Tester",
78
+ buyerEmail: "tester@letitrip.in",
79
+ listedPrice: 1299,
80
+ offerAmount: 1000,
81
+ counterAmount: 1150,
82
+ currency: "INR",
83
+ status: OfferStatusValues.COUNTERED,
84
+ buyerNote: "Sandbox offer — seller has countered, accept it to test the counter path.",
85
+ sellerNote: "Counter: ₹1,150.",
86
+ expiresAt: hoursFromNow(24),
87
+ respondedAt: hoursAgo(1),
88
+ createdAt: hoursAgo(2),
89
+ updatedAt: hoursAgo(1),
90
+ isTestData: true,
91
+ testDataExpiresAt: testDataExpiresAt(),
92
+ },
93
+ /**
94
+ * ACCEPTED with a deliberately SHORT window, so the live countdown and the
95
+ * "pay before it closes" case are observable inside one test session rather
96
+ * than needing a 36-hour wait.
97
+ */
98
+ {
99
+ id: "offer-tester-sandbox-expiring",
100
+ productId: "product-beyblade-x-wizard-arrow",
101
+ productTitle: "Beyblade X Wizard Arrow",
102
+ productSlug: "product-beyblade-x-wizard-arrow",
103
+ storeId: "store-beyblade-arena",
104
+ storeName: "Beyblade Arena",
105
+ buyerUid: "user-tester-qa",
106
+ buyerName: "QA Tester",
107
+ buyerEmail: "tester@letitrip.in",
108
+ listedPrice: 899,
109
+ offerAmount: 700,
110
+ lockedPrice: 700,
111
+ currency: "INR",
112
+ status: OfferStatusValues.ACCEPTED,
113
+ buyerNote: "Sandbox offer — accepted with a short checkout window.",
114
+ sellerNote: "Accepted. Pay soon!",
115
+ expiresAt: hoursFromNow(1),
116
+ acceptedAt: hoursAgo(0),
117
+ respondedAt: hoursAgo(0),
118
+ checkoutDeadline: new Date(NOW.getTime() + 30 * 60000),
119
+ createdAt: hoursAgo(1),
120
+ updatedAt: hoursAgo(0),
121
+ isTestData: true,
122
+ testDataExpiresAt: testDataExpiresAt(),
123
+ },
124
+ /**
125
+ * PENDING. Two cases need this: withdrawing an offer, and the
126
+ * "you already have an active offer on this item" rejection when the tester
127
+ * tries to offer on the same listing again.
128
+ */
129
+ {
130
+ id: "offer-tester-sandbox-pending",
131
+ productId: "product-beyblade-original-driger-v",
132
+ productTitle: "Beyblade Original Driger V",
133
+ productSlug: "product-beyblade-original-driger-v",
134
+ storeId: "store-beyblade-arena",
135
+ storeName: "Beyblade Arena",
136
+ buyerUid: "user-tester-qa",
137
+ buyerName: "QA Tester",
138
+ buyerEmail: "tester@letitrip.in",
139
+ listedPrice: 1799,
140
+ offerAmount: 1450,
141
+ currency: "INR",
142
+ status: OfferStatusValues.PENDING,
143
+ buyerNote: "Sandbox offer — still pending, withdraw it to test that path.",
144
+ expiresAt: hoursFromNow(24),
145
+ createdAt: hoursAgo(1),
146
+ updatedAt: hoursAgo(1),
147
+ isTestData: true,
148
+ testDataExpiresAt: testDataExpiresAt(),
149
+ },
150
+ /**
151
+ * The SELLER side. Every fixture above has the tester as the buyer, so
152
+ * accept / decline / counter at /store/offers were unreachable for them —
153
+ * you cannot respond to your own offer. This one is addressed TO the
154
+ * tester's own sandbox store from a different persona.
155
+ */
156
+ {
157
+ id: "offer-tester-sandbox-inbound",
158
+ productId: "product-tester-standard-1",
159
+ productTitle: "Test Gadget — Standard Listing #1",
160
+ productSlug: "product-tester-standard-1",
161
+ storeId: "store-tester-qa-seller",
162
+ storeName: "Tester QA Seller",
163
+ buyerUid: "user-yugi-muto",
164
+ buyerName: "Mock User 3",
165
+ buyerEmail: "rehan.sheikh@gmail.com",
166
+ listedPrice: 150,
167
+ offerAmount: 120,
168
+ currency: "INR",
169
+ status: OfferStatusValues.PENDING,
170
+ buyerNote: "Sandbox inbound offer — accept, counter, or decline it from your store dashboard.",
171
+ expiresAt: hoursFromNow(24),
172
+ createdAt: hoursAgo(2),
173
+ updatedAt: hoursAgo(2),
174
+ isTestData: true,
175
+ testDataExpiresAt: testDataExpiresAt(),
176
+ },
61
177
  ];