@mohasinac/appkit 4.27.0 → 4.29.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.
- package/dist/_internal/client/features/lottery/LotteryAdminEditView.d.ts +16 -16
- package/dist/_internal/client/features/lottery/LotteryAdminEditView.js +29 -6
- package/dist/_internal/client/features/lottery/LotteryListView.js +13 -1
- package/dist/_internal/server/features/checkout/actions.js +6 -4
- package/dist/_internal/server/features/classified/metadata.js +3 -1
- package/dist/_internal/server/features/digital-code/metadata.js +3 -1
- package/dist/_internal/server/features/live/metadata.js +3 -1
- package/dist/_internal/server/features/refunds/actions.js +3 -2
- package/dist/_internal/server/features/reviews/actions.js +3 -2
- package/dist/_internal/server/features/seo/sitemap.js +189 -40
- package/dist/_internal/server/features/stores/adapters.d.ts +1 -1
- package/dist/_internal/server/features/stores/adapters.js +5 -0
- package/dist/_internal/server/jobs/core/listingProcessor.d.ts +0 -1
- package/dist/_internal/server/jobs/core/listingProcessor.js +19 -1
- package/dist/_internal/shared/actions/action-registry.js +14 -0
- package/dist/_internal/shared/checkout/order-math.d.ts +25 -3
- package/dist/_internal/shared/features/checkout/config.d.ts +3 -3
- package/dist/_internal/shared/features/checkout/config.js +6 -3
- package/dist/client.d.ts +32 -2
- package/dist/client.js +37 -2
- package/dist/constants/api-endpoints.d.ts +21 -3
- package/dist/constants/api-endpoints.js +14 -1
- package/dist/constants/field-names.d.ts +2 -2
- package/dist/constants/field-names.js +2 -2
- package/dist/core/newsletter.repository.js +14 -1
- package/dist/features/about/components/FAQPageView.js +1 -1
- package/dist/features/about/components/FeesView.js +1 -1
- package/dist/features/account/components/AddressForm.d.ts +2 -0
- package/dist/features/account/components/AddressForm.js +5 -1
- package/dist/features/account/components/UserBidsView.js +1 -1
- package/dist/features/account/components/UserSidebar.js +1 -1
- package/dist/features/account/components/UserSupportView.js +24 -2
- package/dist/features/account/hooks/useAddresses.d.ts +29 -1
- package/dist/features/account/hooks/useAddresses.js +4 -1
- package/dist/features/account/hooks/useProfile.d.ts +1 -1
- package/dist/features/account/hooks/useProfile.js +1 -1
- package/dist/features/addresses/repository/addresses.repository.d.ts +13 -0
- package/dist/features/addresses/repository/addresses.repository.js +19 -0
- package/dist/features/admin/actions/chat-actions.js +5 -1
- package/dist/features/admin/components/AdminAdsView.js +1 -1
- package/dist/features/admin/components/AdminBidsView.js +6 -1
- package/dist/features/admin/components/AdminCarouselGroupEditorView.d.ts +9 -1
- package/dist/features/admin/components/AdminCarouselGroupEditorView.js +42 -10
- package/dist/features/admin/components/AdminCarouselView.js +1 -1
- package/dist/features/admin/components/AdminContentGuideView.js +1 -1
- package/dist/features/admin/components/AdminFeatureEditorView.js +1 -1
- package/dist/features/admin/components/AdminGroupedListingsView.js +14 -2
- package/dist/features/admin/components/AdminSidebar.js +1 -1
- package/dist/features/admin/components/AdminViewCards.js +2 -2
- package/dist/features/admin/components/DataTable.js +2 -2
- package/dist/features/admin/schemas/firestore.js +9 -3
- package/dist/features/auctions/actions/bid-actions.js +45 -4
- package/dist/features/auctions/components/AuctionBottomActions.d.ts +21 -6
- package/dist/features/auctions/components/AuctionBottomActions.js +42 -11
- package/dist/features/auctions/components/AuctionDetailPageView.d.ts +8 -3
- package/dist/features/auctions/components/AuctionDetailPageView.js +2 -2
- package/dist/features/auctions/components/MarketplaceAuctionCard.js +4 -5
- package/dist/features/auctions/components/PlaceBidFormClient.d.ts +27 -2
- package/dist/features/auctions/components/PlaceBidFormClient.js +42 -20
- package/dist/features/auth/components/SocialAuthButtons.js +1 -1
- package/dist/features/auth/hooks/useAuth.d.ts +23 -1
- package/dist/features/auth/hooks/useAuth.js +27 -1
- package/dist/features/auth/permissions/constants.d.ts +1 -1
- package/dist/features/auth/permissions/constants.js +3 -0
- package/dist/features/auth/repository/session.repository.d.ts +16 -1
- package/dist/features/auth/repository/session.repository.js +23 -0
- package/dist/features/auth/repository/user.repository.js +13 -2
- package/dist/features/blog/components/BlogListView.js +2 -2
- package/dist/features/blog/repository/blog.repository.d.ts +4 -0
- package/dist/features/blog/repository/blog.repository.js +1 -0
- package/dist/features/blog/schemas/firestore.d.ts +3 -1
- package/dist/features/blog/schemas/firestore.js +1 -0
- package/dist/features/cart/components/CartPriceBreakdown.d.ts +11 -1
- package/dist/features/cart/components/CartPriceBreakdown.js +3 -3
- package/dist/features/cart/components/StoreAddonsPicker.d.ts +9 -0
- package/dist/features/cart/components/StoreAddonsPicker.js +15 -5
- package/dist/features/cart/components/index.d.ts +1 -1
- package/dist/features/cart/components/index.js +1 -1
- package/dist/features/cart/hooks/useGuestCartMerge.d.ts +8 -1
- package/dist/features/cart/hooks/useGuestCartMerge.js +2 -1
- package/dist/features/cart/utils/line-total.d.ts +25 -0
- package/dist/features/cart/utils/line-total.js +26 -0
- package/dist/features/catalogue/repository/catalogue.repository.d.ts +12 -0
- package/dist/features/catalogue/repository/catalogue.repository.js +15 -0
- package/dist/features/categories/components/CategoryTree.js +2 -2
- package/dist/features/contact/components/ContactForm.js +1 -1
- package/dist/features/copilot/hooks/useCopilotFeedback.d.ts +1 -1
- package/dist/features/copilot/hooks/useCopilotFeedback.js +1 -1
- package/dist/features/events/components/AdminEventEditorView.js +16 -9
- package/dist/features/events/components/AdminEventEntriesView.js +7 -13
- package/dist/features/events/components/EventRafflesSection.js +14 -2
- package/dist/features/events/components/EventStatusBadge.js +1 -1
- package/dist/features/events/components/event-entry-detail-fields.d.ts +24 -0
- package/dist/features/events/components/event-entry-detail-fields.js +13 -0
- package/dist/features/events/repository/events.repository.js +1 -0
- package/dist/features/events/schemas/firestore.d.ts +3 -1
- package/dist/features/events/schemas/firestore.js +1 -0
- package/dist/features/faq/components/ContactCTA.js +1 -1
- package/dist/features/faq/components/FAQHelpfulButtons.js +2 -2
- package/dist/features/faq/repository/faqs.repository.d.ts +16 -1
- package/dist/features/faq/repository/faqs.repository.js +64 -54
- package/dist/features/faq/schemas/firestore.d.ts +3 -2
- package/dist/features/faq/schemas/firestore.js +2 -2
- package/dist/features/faq/schemas/index.d.ts +3 -3
- package/dist/features/faq/schemas/index.js +1 -1
- package/dist/features/filters/FilterFacetSection.js +2 -2
- package/dist/features/forms/Toggle.js +1 -1
- package/dist/features/grouped/components/GroupedListingEditorView.d.ts +18 -0
- package/dist/features/grouped/components/GroupedListingEditorView.js +192 -0
- package/dist/features/homepage/components/AdvertisementBanner.js +2 -2
- package/dist/features/homepage/components/BrandsSection.js +1 -1
- package/dist/features/homepage/components/CTABannerSection.js +1 -1
- package/dist/features/homepage/components/HomepageCustomerReviewsSection.js +1 -1
- package/dist/features/homepage/components/HomepageSectionBoundary.d.ts +39 -0
- package/dist/features/homepage/components/HomepageSectionBoundary.js +49 -0
- package/dist/features/homepage/components/ShopByCategorySection.js +1 -1
- package/dist/features/homepage/components/WelcomeSection.js +1 -1
- package/dist/features/homepage/lib/section-renderer.js +2 -1
- package/dist/features/layout/AppLayoutShell.js +5 -5
- package/dist/features/layout/BottomActions.js +5 -5
- package/dist/features/layout/BottomSheet.js +1 -1
- package/dist/features/layout/MainNavbar.js +1 -1
- package/dist/features/layout/NavbarLayout.js +1 -1
- package/dist/features/layout/TitleBarLayout.js +3 -3
- package/dist/features/layout/hooks/useFormBottomActions.d.ts +11 -1
- package/dist/features/layout/hooks/useFormBottomActions.js +16 -2
- package/dist/features/lottery/schemas/config-write.d.ts +141 -0
- package/dist/features/lottery/schemas/config-write.js +139 -0
- package/dist/features/media/MediaPickerModal.js +3 -1
- package/dist/features/media/MediaVideo.js +4 -2
- package/dist/features/media/components/MediaSlider.js +1 -1
- package/dist/features/messages/repository/conversations.repository.js +15 -5
- package/dist/features/orders/components/OrdersList.js +2 -2
- package/dist/features/payments/repository/payout.repository.d.ts +11 -1
- package/dist/features/payments/repository/payout.repository.js +14 -6
- package/dist/features/pre-orders/components/MarketplacePreorderCard.js +3 -2
- package/dist/features/pre-orders/components/PreOrderBadge.js +1 -1
- package/dist/features/pre-orders/components/PreOrderDetailPageView.js +1 -1
- package/dist/features/products/columns/productTableColumns.js +3 -3
- package/dist/features/products/components/CompareOverlay.js +1 -1
- package/dist/features/products/components/PrizeDrawDetailPageView.js +1 -1
- package/dist/features/products/components/PrizeDrawEntryActions.js +2 -2
- package/dist/features/products/components/PrizeDrawsSection.js +5 -1
- package/dist/features/products/components/ProductDetailActions.js +11 -7
- package/dist/features/products/components/ProductDetailPageView.js +3 -3
- package/dist/features/products/components/ProductFeatureBadges.js +2 -2
- package/dist/features/products/components/ProductFeaturesSelector.js +1 -1
- package/dist/features/products/components/ProductFilters.js +15 -8
- package/dist/features/products/components/ProductGrid.js +8 -17
- package/dist/features/products/components/ProductTabs.js +7 -4
- package/dist/features/products/components/ProductTabsShell.js +2 -7
- package/dist/features/products/constants/action-defs.d.ts +21 -4
- package/dist/features/products/constants/action-defs.js +7 -3
- package/dist/features/products/hooks/useRelatedProducts.js +2 -1
- package/dist/features/products/repository/products.repository.d.ts +1 -1
- package/dist/features/products/repository/products.repository.js +38 -16
- package/dist/features/products/schemas/firestore.d.ts +3 -2
- package/dist/features/products/schemas/firestore.js +1 -1
- package/dist/features/reviews/actions/review-actions.d.ts +8 -1
- package/dist/features/reviews/actions/review-actions.js +14 -3
- package/dist/features/reviews/components/ReviewDetailShell.js +10 -4
- package/dist/features/reviews/components/ReviewModal.js +1 -1
- package/dist/features/reviews/repository/reviews.repository.d.ts +29 -1
- package/dist/features/reviews/repository/reviews.repository.js +54 -13
- package/dist/features/reviews/schemas/firestore.d.ts +9 -1
- package/dist/features/reviews/schemas/firestore.js +1 -0
- package/dist/features/scams/components/ScamRegistryView.js +2 -2
- package/dist/features/search/components/Search.js +3 -3
- package/dist/features/search/components/SearchResultsSection.js +1 -1
- package/dist/features/seller/components/SellerAddressesView.js +3 -1
- package/dist/features/seller/components/SellerBidsView.js +6 -1
- package/dist/features/seller/components/SellerSidebar.js +1 -1
- package/dist/features/shell/SectionForm.d.ts +21 -1
- package/dist/features/shell/SectionForm.js +15 -3
- package/dist/features/shell/build-sections.js +10 -1
- package/dist/features/shell/field-ui-meta.d.ts +21 -0
- package/dist/features/shipments/components/AdminShipmentLotItemsView.js +23 -6
- package/dist/features/site-settings/components/ActionPermissionsManager.js +1 -1
- package/dist/features/store-extensions/repository/store-extensions.repositories.d.ts +21 -4
- package/dist/features/store-extensions/repository/store-extensions.repositories.js +24 -4
- package/dist/features/store-extensions/schemas/shipping-config-form.js +13 -0
- package/dist/features/store-extensions/schemas/store-category-form.js +1 -1
- package/dist/features/stores/actions/store-query-actions.js +25 -1
- package/dist/features/stores/components/InteractiveStoreCard.js +1 -1
- package/dist/features/stores/components/StoreHeader.js +1 -1
- package/dist/features/stores/components/StoreNavTabs.js +20 -8
- package/dist/features/stores/repository/store.repository.js +1 -0
- package/dist/features/stores/schemas/firestore.d.ts +2 -0
- package/dist/features/support/repository/support.repository.d.ts +12 -0
- package/dist/features/support/repository/support.repository.js +15 -0
- package/dist/features/support/schemas/ticket-create-form.d.ts +33 -0
- package/dist/features/support/schemas/ticket-create-form.js +82 -0
- package/dist/features/tester/repository/tester-checklist-item.repository.d.ts +0 -1
- package/dist/features/tester/repository/tester-checklist-item.repository.js +6 -15
- package/dist/features/tester/schemas/firestore.d.ts +5 -4
- package/dist/features/tester/schemas/firestore.js +3 -3
- package/dist/features/tester/seed-data/products-tester-seed-data.js +2 -2
- package/dist/features/tester/seed-data/tester-checklist-seed-data.js +138 -1
- package/dist/features/wishlist/components/WishlistHeartButton.d.ts +55 -0
- package/dist/features/wishlist/components/WishlistHeartButton.js +52 -0
- package/dist/features/wishlist/components/index.d.ts +2 -1
- package/dist/features/wishlist/components/index.js +1 -1
- package/dist/index.d.ts +10 -3
- package/dist/index.js +19 -4
- package/dist/monitoring/error-tracking.js +39 -5
- package/dist/monitoring/server-logger.js +70 -32
- package/dist/next/components/ErrorView.js +1 -1
- package/dist/next/routing/route-map.d.ts +39 -7
- package/dist/next/routing/route-map.js +34 -4
- package/dist/providers/db-firebase/base.repository.d.ts +30 -0
- package/dist/providers/db-firebase/base.repository.js +56 -9
- package/dist/react/ErrorBoundary.js +9 -1
- package/dist/react/contexts/SessionContext.js +6 -2
- package/dist/react/hooks/useAuthGate.d.ts +22 -0
- package/dist/react/hooks/useAuthGate.js +86 -7
- package/dist/schemas/registry.d.ts +3 -3
- package/dist/security/index.d.ts +1 -1
- package/dist/security/index.js +1 -1
- package/dist/security/pii-encrypt.d.ts +13 -5
- package/dist/security/pii-encrypt.js +132 -6
- package/dist/security/pii-schemas.d.ts +32 -4
- package/dist/security/pii-schemas.js +38 -5
- package/dist/seed/_helpers/product-search-txt.d.ts +18 -0
- package/dist/seed/_helpers/product-search-txt.js +33 -0
- package/dist/seed/_helpers/search-txt-wrappers.d.ts +20 -0
- package/dist/seed/_helpers/search-txt-wrappers.js +73 -0
- package/dist/seed/blog-posts-seed-data.d.ts +4 -0
- package/dist/seed/blog-posts-seed-data.js +7 -1
- package/dist/seed/events-seed-data.d.ts +5 -1
- package/dist/seed/events-seed-data.js +7 -1
- package/dist/seed/faq-seed-data.d.ts +16 -0
- package/dist/seed/faq-seed-data.js +22 -1
- package/dist/seed/products-art-seed-data.js +49 -7
- package/dist/seed/products-auctions-seed-data.js +12 -4
- package/dist/seed/products-classifieds-seed-data.d.ts +5 -0
- package/dist/seed/products-classifieds-seed-data.js +65 -9
- package/dist/seed/products-digital-codes-seed-data.d.ts +5 -0
- package/dist/seed/products-digital-codes-seed-data.js +65 -9
- package/dist/seed/products-live-items-seed-data.d.ts +5 -0
- package/dist/seed/products-live-items-seed-data.js +33 -5
- package/dist/seed/products-preorders-seed-data.d.ts +1 -1
- package/dist/seed/products-preorders-seed-data.js +6 -2
- package/dist/seed/products-prize-draws-seed-data.d.ts +5 -0
- package/dist/seed/products-prize-draws-seed-data.js +57 -8
- package/dist/seed/products-standard-seed-data.js +6 -2
- package/dist/seed/products-stickers-seed-data.js +49 -7
- package/dist/seed/reviews-seed-data.js +2 -1
- package/dist/seed/site-settings-seed-data.js +5 -3
- package/dist/seed/stores-seed-data.d.ts +4 -0
- package/dist/seed/stores-seed-data.js +7 -1
- package/dist/seo/json-ld.d.ts +44 -2
- package/dist/seo/json-ld.js +57 -11
- package/dist/styles.css +368 -90
- package/dist/tailwind-utilities.css +1 -1
- package/dist/tokens/index.d.ts +1 -1
- package/dist/tokens/index.js +1 -1
- package/dist/tokens/themes/default-dark.js +6 -0
- package/dist/tokens/themes/default-light.js +5 -0
- package/dist/tokens/tokens.css +84 -0
- package/dist/ui/DataTable.js +1 -1
- package/dist/ui/DataTable.style.css +3 -3
- package/dist/ui/components/BulkActionBar.style.css +1 -3
- package/dist/ui/components/Button.js +15 -6
- package/dist/ui/components/Dropdown.style.css +1 -4
- package/dist/ui/components/FilterChipGroup.js +1 -1
- package/dist/ui/components/FilterDrawer.style.css +1 -1
- package/dist/ui/components/Icon.d.ts +53 -0
- package/dist/ui/components/Icon.js +41 -0
- package/dist/ui/components/IconButton.d.ts +13 -0
- package/dist/ui/components/IconButton.js +13 -0
- package/dist/ui/components/IconButton.style.css +18 -10
- package/dist/ui/components/ListingLayout.style.css +2 -10
- package/dist/ui/components/ListingToolbar.js +6 -6
- package/dist/ui/components/Modal.js +1 -1
- package/dist/ui/components/PaginatedSelect.style.css +3 -3
- package/dist/ui/components/Pagination.style.css +1 -6
- package/dist/ui/components/RichTextEditor.js +1 -1
- package/dist/ui/components/RowActionMenu.style.css +1 -1
- package/dist/ui/components/SideDrawer.style.css +1 -1
- package/dist/ui/components/Slider.js +1 -1
- package/dist/ui/components/TabBarShell.d.ts +78 -0
- package/dist/ui/components/TabBarShell.js +95 -0
- package/dist/ui/components/Tabs.js +12 -8
- package/dist/ui/components/Tabs.style.css +249 -41
- package/dist/ui/components/ViewToggle.style.css +1 -5
- package/dist/ui/components/tabs-overflow.d.ts +17 -0
- package/dist/ui/components/tabs-overflow.js +142 -0
- package/dist/ui/icons/icon-registry.d.ts +38 -0
- package/dist/ui/icons/icon-registry.js +37 -0
- package/dist/ui/index.d.ts +6 -0
- package/dist/ui/index.js +3 -0
- package/dist/utils/index.d.ts +1 -1
- package/dist/utils/index.js +1 -1
- package/dist/utils/media-url.d.ts +27 -4
- package/dist/utils/media-url.js +37 -6
- package/dist/utils/search-txt.d.ts +71 -0
- package/dist/utils/search-txt.js +118 -0
- package/package.json +1 -1
|
@@ -13,12 +13,13 @@
|
|
|
13
13
|
* @tag consumers:seed/index.ts,seed/runner.ts
|
|
14
14
|
* @tag sideEffects:none
|
|
15
15
|
*/
|
|
16
|
+
import { withEventSearchTxt } from "./_helpers/search-txt-wrappers";
|
|
16
17
|
import { EVENT_FIELDS, EVENT_ENTRY_FIELDS } from "../features/events/schemas";
|
|
17
18
|
import { seedExtMedia } from "./_helpers/media";
|
|
18
19
|
const NOW = new Date();
|
|
19
20
|
const daysAgo = (n) => new Date(NOW.getTime() - n * 86400000);
|
|
20
21
|
const daysAhead = (n) => new Date(NOW.getTime() + n * 86400000);
|
|
21
|
-
|
|
22
|
+
const _raweventsSeedData = [
|
|
22
23
|
// ── 1. ACTIVE — Poll: Favourite Blader Original Series ────────────────────
|
|
23
24
|
{
|
|
24
25
|
id: "event-favourite-blader-poll",
|
|
@@ -469,3 +470,8 @@ export const eventEntriesSeedData = [
|
|
|
469
470
|
createdAt: daysAgo(2),
|
|
470
471
|
},
|
|
471
472
|
];
|
|
473
|
+
/**
|
|
474
|
+
* Tokens derived here, not per record — see _helpers/search-txt-wrappers.ts for
|
|
475
|
+
* why the wrapper form is what makes omission impossible.
|
|
476
|
+
*/
|
|
477
|
+
export const eventsSeedData = _raweventsSeedData.map(withEventSearchTxt);
|
|
@@ -1,2 +1,18 @@
|
|
|
1
1
|
import type { FAQDocument } from "../features/faq/schemas";
|
|
2
|
+
/**
|
|
3
|
+
* Derive `searchTxt` for every record from its own content.
|
|
4
|
+
*
|
|
5
|
+
* This is why FAQ search returned nothing: the seed writes documents raw via
|
|
6
|
+
* `batch.set()` (both `seed/runner.ts` and `seed-cli.mjs`), bypassing
|
|
7
|
+
* `FirebaseFAQsRepository.create()` — the only thing that built tokens. So all
|
|
8
|
+
* 63 seeded FAQs had no `searchTokens` field at all and `array-contains`
|
|
9
|
+
* matched zero documents, for every query, forever.
|
|
10
|
+
*
|
|
11
|
+
* Derived here rather than hand-written per record so a new FAQ cannot be added
|
|
12
|
+
* without tokens, and computed with the SAME `buildFaqSearchTxt` the repository
|
|
13
|
+
* uses so seeded and admin-created FAQs are byte-identical.
|
|
14
|
+
*
|
|
15
|
+
* Pure function of the record's own content — deterministic, so this does not
|
|
16
|
+
* reintroduce the `appkit-seed` idempotency problem of Root Cause #25.
|
|
17
|
+
*/
|
|
2
18
|
export declare const faqSeedData: Partial<FAQDocument>[];
|
|
@@ -16,11 +16,12 @@
|
|
|
16
16
|
* @tag consumers:seed/index.ts,seed/runner.ts
|
|
17
17
|
* @tag sideEffects:none
|
|
18
18
|
*/
|
|
19
|
+
import { buildFaqSearchTxt } from "../features/faq/repository/faqs.repository";
|
|
19
20
|
const NOW = new Date();
|
|
20
21
|
const daysAgo = (n) => new Date(NOW.getTime() - n * 86400000);
|
|
21
22
|
const html = (text) => ({ text, format: "html" });
|
|
22
23
|
const makeStats = (views = 0, helpful = 0) => ({ views, helpful, notHelpful: 0 });
|
|
23
|
-
|
|
24
|
+
const faqSeedRecords = [
|
|
24
25
|
// ── GENERAL (10) ────────────────────────────────────────────────────────────
|
|
25
26
|
{
|
|
26
27
|
id: "faq-what-is-letitrip",
|
|
@@ -1234,3 +1235,23 @@ export const faqSeedData = [
|
|
|
1234
1235
|
updatedAt: daysAgo(1),
|
|
1235
1236
|
},
|
|
1236
1237
|
];
|
|
1238
|
+
/**
|
|
1239
|
+
* Derive `searchTxt` for every record from its own content.
|
|
1240
|
+
*
|
|
1241
|
+
* This is why FAQ search returned nothing: the seed writes documents raw via
|
|
1242
|
+
* `batch.set()` (both `seed/runner.ts` and `seed-cli.mjs`), bypassing
|
|
1243
|
+
* `FirebaseFAQsRepository.create()` — the only thing that built tokens. So all
|
|
1244
|
+
* 63 seeded FAQs had no `searchTokens` field at all and `array-contains`
|
|
1245
|
+
* matched zero documents, for every query, forever.
|
|
1246
|
+
*
|
|
1247
|
+
* Derived here rather than hand-written per record so a new FAQ cannot be added
|
|
1248
|
+
* without tokens, and computed with the SAME `buildFaqSearchTxt` the repository
|
|
1249
|
+
* uses so seeded and admin-created FAQs are byte-identical.
|
|
1250
|
+
*
|
|
1251
|
+
* Pure function of the record's own content — deterministic, so this does not
|
|
1252
|
+
* reintroduce the `appkit-seed` idempotency problem of Root Cause #25.
|
|
1253
|
+
*/
|
|
1254
|
+
export const faqSeedData = faqSeedRecords.map((faq) => ({
|
|
1255
|
+
...faq,
|
|
1256
|
+
searchTxt: buildFaqSearchTxt(faq),
|
|
1257
|
+
}));
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
* @tag sideEffects:none
|
|
19
19
|
*/
|
|
20
20
|
import { PRODUCT_FIELDS } from "../constants/field-names";
|
|
21
|
-
import {
|
|
21
|
+
import { buildSearchTxt } from "../utils/search-txt";
|
|
22
22
|
import { seedExtMedia } from "./_helpers/media";
|
|
23
23
|
export const productsArtSeedData = [
|
|
24
24
|
{
|
|
@@ -54,7 +54,14 @@ export const productsArtSeedData = [
|
|
|
54
54
|
tags: ["fan-art", "poster"],
|
|
55
55
|
createdAt: new Date("2026-08-17"),
|
|
56
56
|
updatedAt: new Date("2026-08-17"),
|
|
57
|
-
|
|
57
|
+
searchTxt: buildSearchTxt([
|
|
58
|
+
"Dranzer Phoenix Rising — Fan Art Poster",
|
|
59
|
+
"Vibrant fan-art poster of Dranzer erupting in phoenix flame.",
|
|
60
|
+
"Beyblade",
|
|
61
|
+
"brand-beyblade",
|
|
62
|
+
["Spinning Tops"],
|
|
63
|
+
["fan-art", "poster"],
|
|
64
|
+
]),
|
|
58
65
|
},
|
|
59
66
|
{
|
|
60
67
|
id: "art-valkyrie-holographic-print",
|
|
@@ -89,7 +96,14 @@ export const productsArtSeedData = [
|
|
|
89
96
|
tags: ["fan-art", "limited-run"],
|
|
90
97
|
createdAt: new Date("2026-08-18"),
|
|
91
98
|
updatedAt: new Date("2026-08-19"),
|
|
92
|
-
|
|
99
|
+
searchTxt: buildSearchTxt([
|
|
100
|
+
"Beyblade Burst Valkyrie — Holographic Art Print (Limited /100)",
|
|
101
|
+
"Limited-edition holographic art print of Valkyrie, numbered out of 100.",
|
|
102
|
+
"Beyblade",
|
|
103
|
+
"brand-beyblade",
|
|
104
|
+
["Beyblade Burst", "Spinning Tops"],
|
|
105
|
+
["fan-art", "limited-run"],
|
|
106
|
+
]),
|
|
93
107
|
},
|
|
94
108
|
{
|
|
95
109
|
id: "art-beyblade-x-lineup-canvas",
|
|
@@ -127,7 +141,14 @@ export const productsArtSeedData = [
|
|
|
127
141
|
tags: ["fan-art", "canvas"],
|
|
128
142
|
createdAt: new Date("2026-08-19"),
|
|
129
143
|
updatedAt: new Date("2026-08-19"),
|
|
130
|
-
|
|
144
|
+
searchTxt: buildSearchTxt([
|
|
145
|
+
"Beyblade X Full Lineup — Canvas Print",
|
|
146
|
+
"Gallery-style canvas print featuring the full current Beyblade X roster.",
|
|
147
|
+
"Takara-Tomy",
|
|
148
|
+
"brand-takara-tomy",
|
|
149
|
+
["Beyblade X", "Spinning Tops"],
|
|
150
|
+
["fan-art", "canvas"],
|
|
151
|
+
]),
|
|
131
152
|
},
|
|
132
153
|
{
|
|
133
154
|
id: "art-metal-fight-vintage-poster",
|
|
@@ -159,7 +180,14 @@ export const productsArtSeedData = [
|
|
|
159
180
|
tags: ["fan-art", "poster", "vintage-collectible"],
|
|
160
181
|
createdAt: new Date("2026-08-19"),
|
|
161
182
|
updatedAt: new Date("2026-08-19"),
|
|
162
|
-
|
|
183
|
+
searchTxt: buildSearchTxt([
|
|
184
|
+
"Metal Fight Beyblade — Vintage-Style Poster (Open Edition)",
|
|
185
|
+
"Retro-styled poster celebrating the Metal Fight era, open edition.",
|
|
186
|
+
"Takara-Tomy",
|
|
187
|
+
"brand-takara-tomy",
|
|
188
|
+
["Beyblade Metal Fight", "Spinning Tops"],
|
|
189
|
+
["fan-art", "poster", "vintage-collectible"],
|
|
190
|
+
]),
|
|
163
191
|
},
|
|
164
192
|
{
|
|
165
193
|
id: "art-original-series-anniversary-print",
|
|
@@ -194,7 +222,14 @@ export const productsArtSeedData = [
|
|
|
194
222
|
tags: ["fan-art", "vintage-collectible", "limited-run"],
|
|
195
223
|
createdAt: new Date("2026-08-19"),
|
|
196
224
|
updatedAt: new Date("2026-08-19"),
|
|
197
|
-
|
|
225
|
+
searchTxt: buildSearchTxt([
|
|
226
|
+
"Original Series 25th Anniversary — Glossy Art Print",
|
|
227
|
+
"Commemorative glossy print marking 25 years of the original Beyblade series.",
|
|
228
|
+
"Beyblade",
|
|
229
|
+
"brand-beyblade",
|
|
230
|
+
["Beyblade Original", "Spinning Tops"],
|
|
231
|
+
["fan-art", "vintage-collectible", "limited-run"],
|
|
232
|
+
]),
|
|
198
233
|
},
|
|
199
234
|
{
|
|
200
235
|
// Sold-out fixture. The canonical unavailable shape for a stock-only type:
|
|
@@ -232,6 +267,13 @@ export const productsArtSeedData = [
|
|
|
232
267
|
tags: ["fan-art", "poster", "sold-out"],
|
|
233
268
|
createdAt: new Date("2026-08-24"),
|
|
234
269
|
updatedAt: new Date("2026-08-24"),
|
|
235
|
-
|
|
270
|
+
searchTxt: buildSearchTxt([
|
|
271
|
+
"Dragoon Galaxy Turbo — Fan Art Print (Sold Out)",
|
|
272
|
+
"A sold-out run of the Dragoon Galaxy Turbo fan-art print.",
|
|
273
|
+
"Beyblade",
|
|
274
|
+
"brand-beyblade",
|
|
275
|
+
["Beyblade Original", "Spinning Tops"],
|
|
276
|
+
["fan-art", "poster", "sold-out"],
|
|
277
|
+
]),
|
|
236
278
|
},
|
|
237
279
|
];
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
* @tag sideEffects:none
|
|
24
24
|
*/
|
|
25
25
|
import { PRODUCT_FIELDS } from "../constants/field-names";
|
|
26
|
-
import {
|
|
26
|
+
import { buildSearchTxt } from "../utils/search-txt";
|
|
27
27
|
import { seedExtMedia } from "./_helpers/media";
|
|
28
28
|
function withTokens(p) {
|
|
29
29
|
return {
|
|
@@ -33,7 +33,11 @@ function withTokens(p) {
|
|
|
33
33
|
stockQuantity: 1,
|
|
34
34
|
availableQuantity: p.isSold ? 0 : 1,
|
|
35
35
|
...p,
|
|
36
|
-
|
|
36
|
+
searchTxt: buildSearchTxt([
|
|
37
|
+
p.title, p.description, p.brand, p.brandSlug,
|
|
38
|
+
p.categoryNames, p.tags, p.features, p.condition,
|
|
39
|
+
p.specifications?.map((s) => `${s.name} ${s.value}`),
|
|
40
|
+
]),
|
|
37
41
|
};
|
|
38
42
|
}
|
|
39
43
|
const DRANZER_SPECS = [
|
|
@@ -393,8 +397,12 @@ const _rawProductsAuctionsSeedData = [
|
|
|
393
397
|
updatedAt: new Date("2026-08-19"),
|
|
394
398
|
},
|
|
395
399
|
];
|
|
400
|
+
// `.map(withTokens)` is applied to the WHOLE array at the end, not just to the
|
|
401
|
+
// spread above. It used to wrap only the spread, so the ended-unsold fixture
|
|
402
|
+
// appended after it shipped with no searchTxt — the one row that proves the
|
|
403
|
+
// auction availability branch works, invisible to search.
|
|
396
404
|
export const productsAuctionsSeedData = [
|
|
397
|
-
..._rawProductsAuctionsSeedData.map((a) =>
|
|
405
|
+
..._rawProductsAuctionsSeedData.map((a) => ({
|
|
398
406
|
...a,
|
|
399
407
|
listingType: PRODUCT_FIELDS.LISTING_TYPE_VALUES.AUCTION,
|
|
400
408
|
})),
|
|
@@ -434,4 +442,4 @@ export const productsAuctionsSeedData = [
|
|
|
434
442
|
createdAt: new Date("2026-08-10"),
|
|
435
443
|
updatedAt: new Date("2026-08-24"),
|
|
436
444
|
},
|
|
437
|
-
];
|
|
445
|
+
].map(withTokens);
|
|
@@ -1,2 +1,7 @@
|
|
|
1
1
|
import { ProductDocument } from "../features/products/schemas/firestore";
|
|
2
|
+
/**
|
|
3
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
4
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
5
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
6
|
+
*/
|
|
2
7
|
export declare const productsClassifiedsSeedData: Partial<ProductDocument>[];
|
|
@@ -18,10 +18,11 @@
|
|
|
18
18
|
* @tag consumers:seed/index.ts,seed/runner.ts
|
|
19
19
|
* @tag sideEffects:none
|
|
20
20
|
*/
|
|
21
|
+
import { withProductSearchTxt } from "./_helpers/product-search-txt";
|
|
21
22
|
import { PRODUCT_FIELDS } from "../constants/field-names";
|
|
22
|
-
import {
|
|
23
|
+
import { buildSearchTxt } from "../utils/search-txt";
|
|
23
24
|
import { seedExtMedia } from "./_helpers/media";
|
|
24
|
-
|
|
25
|
+
const _rawproductsClassifiedsSeedData = [
|
|
25
26
|
{
|
|
26
27
|
id: "classified-beyblade-stadium-set",
|
|
27
28
|
slug: "classified-beyblade-stadium-set",
|
|
@@ -66,7 +67,14 @@ export const productsClassifiedsSeedData = [
|
|
|
66
67
|
tags: ["classified", "local-pickup"],
|
|
67
68
|
createdAt: new Date("2026-05-05"),
|
|
68
69
|
updatedAt: new Date("2026-05-05"),
|
|
69
|
-
|
|
70
|
+
searchTxt: buildSearchTxt([
|
|
71
|
+
"Used Beyblade Stadium Set — Local Pickup Only",
|
|
72
|
+
"Well-loved Beyblade stadium with 6 tops and 2 launchers.",
|
|
73
|
+
"Beyblade",
|
|
74
|
+
"brand-beyblade",
|
|
75
|
+
["Spinning Tops"],
|
|
76
|
+
["classified", "local-pickup"],
|
|
77
|
+
]),
|
|
70
78
|
},
|
|
71
79
|
{
|
|
72
80
|
id: "classified-beyblade-burst-collection-bengaluru",
|
|
@@ -106,7 +114,14 @@ export const productsClassifiedsSeedData = [
|
|
|
106
114
|
tags: ["classified", "bulk-lot"],
|
|
107
115
|
createdAt: new Date("2026-08-13"),
|
|
108
116
|
updatedAt: new Date("2026-08-13"),
|
|
109
|
-
|
|
117
|
+
searchTxt: buildSearchTxt([
|
|
118
|
+
"Beyblade Burst Collection (12 Tops) — Bengaluru",
|
|
119
|
+
"Downsizing my Burst collection, fixed price, ships nationwide.",
|
|
120
|
+
"Beyblade",
|
|
121
|
+
"brand-beyblade",
|
|
122
|
+
["Beyblade Burst", "Spinning Tops"],
|
|
123
|
+
["classified", "bulk-lot"],
|
|
124
|
+
]),
|
|
110
125
|
},
|
|
111
126
|
{
|
|
112
127
|
id: "classified-beyblade-x-starter-pune",
|
|
@@ -149,7 +164,14 @@ export const productsClassifiedsSeedData = [
|
|
|
149
164
|
tags: ["classified", "local-pickup", "starter-set"],
|
|
150
165
|
createdAt: new Date("2026-08-14"),
|
|
151
166
|
updatedAt: new Date("2026-08-14"),
|
|
152
|
-
|
|
167
|
+
searchTxt: buildSearchTxt([
|
|
168
|
+
"Beyblade X Starter Pack — Pune, Phone Contact Only",
|
|
169
|
+
"Barely used Beyblade X starter pack, phone/WhatsApp only.",
|
|
170
|
+
"Takara-Tomy",
|
|
171
|
+
"brand-takara-tomy",
|
|
172
|
+
["Beyblade X", "Spinning Tops"],
|
|
173
|
+
["classified", "local-pickup", "starter-set"],
|
|
174
|
+
]),
|
|
153
175
|
},
|
|
154
176
|
{
|
|
155
177
|
id: "classified-beyblade-metal-vintage-delhi",
|
|
@@ -196,7 +218,14 @@ export const productsClassifiedsSeedData = [
|
|
|
196
218
|
tags: ["classified", "bulk-lot", "vintage-collectible"],
|
|
197
219
|
createdAt: new Date("2026-08-15"),
|
|
198
220
|
updatedAt: new Date("2026-08-16"),
|
|
199
|
-
|
|
221
|
+
searchTxt: buildSearchTxt([
|
|
222
|
+
"Vintage Metal Fight Lot (5 Tops) — Delhi NCR",
|
|
223
|
+
"Well-preserved 5-top Metal Fight lot, firm price, ships anywhere.",
|
|
224
|
+
"Takara-Tomy",
|
|
225
|
+
"brand-takara-tomy",
|
|
226
|
+
["Beyblade Metal Fight", "Spinning Tops"],
|
|
227
|
+
["classified", "bulk-lot", "vintage-collectible"],
|
|
228
|
+
]),
|
|
200
229
|
},
|
|
201
230
|
{
|
|
202
231
|
id: "classified-beyblade-original-grail-chennai",
|
|
@@ -236,7 +265,14 @@ export const productsClassifiedsSeedData = [
|
|
|
236
265
|
tags: ["classified", "vintage-collectible", "local-pickup"],
|
|
237
266
|
createdAt: new Date("2026-08-16"),
|
|
238
267
|
updatedAt: new Date("2026-08-16"),
|
|
239
|
-
|
|
268
|
+
searchTxt: buildSearchTxt([
|
|
269
|
+
"Original Series Grail Piece — Chennai, Meet Up Only",
|
|
270
|
+
"Genuine original-series grail piece, local meetup verification only.",
|
|
271
|
+
"Beyblade",
|
|
272
|
+
"brand-beyblade",
|
|
273
|
+
["Beyblade Original", "Spinning Tops"],
|
|
274
|
+
["classified", "vintage-collectible", "local-pickup"],
|
|
275
|
+
]),
|
|
240
276
|
},
|
|
241
277
|
{
|
|
242
278
|
id: "classified-beyblade-x-tournament-kit-hyderabad",
|
|
@@ -282,7 +318,14 @@ export const productsClassifiedsSeedData = [
|
|
|
282
318
|
tags: ["classified", "tournament-grade"],
|
|
283
319
|
createdAt: new Date("2026-08-17"),
|
|
284
320
|
updatedAt: new Date("2026-08-17"),
|
|
285
|
-
|
|
321
|
+
searchTxt: buildSearchTxt([
|
|
322
|
+
"Tournament-Ready Beyblade X Kit — Hyderabad",
|
|
323
|
+
"Complete tournament-legal kit including stadium and scorecard pad.",
|
|
324
|
+
"Takara-Tomy",
|
|
325
|
+
"brand-takara-tomy",
|
|
326
|
+
["Beyblade X", "Spinning Tops"],
|
|
327
|
+
["classified", "tournament-grade"],
|
|
328
|
+
]),
|
|
286
329
|
},
|
|
287
330
|
{
|
|
288
331
|
id: "classified-beyblade-burst-parts-mumbai",
|
|
@@ -325,7 +368,14 @@ export const productsClassifiedsSeedData = [
|
|
|
325
368
|
tags: ["classified", "spare-parts"],
|
|
326
369
|
createdAt: new Date("2026-08-18"),
|
|
327
370
|
updatedAt: new Date("2026-08-18"),
|
|
328
|
-
|
|
371
|
+
searchTxt: buildSearchTxt([
|
|
372
|
+
"Spare Burst Parts Bundle — Mumbai, Ships Too",
|
|
373
|
+
"Assorted spare Burst layers, discs, and drivers.",
|
|
374
|
+
"Beyblade",
|
|
375
|
+
"brand-beyblade",
|
|
376
|
+
["Beyblade Burst", "Spinning Tops"],
|
|
377
|
+
["classified", "spare-parts"],
|
|
378
|
+
]),
|
|
329
379
|
},
|
|
330
380
|
{
|
|
331
381
|
// Sold classified. Keeps `meetupArea.city` populated so the City facet
|
|
@@ -368,3 +418,9 @@ export const productsClassifiedsSeedData = [
|
|
|
368
418
|
updatedAt: new Date("2026-08-24"),
|
|
369
419
|
},
|
|
370
420
|
];
|
|
421
|
+
/**
|
|
422
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
423
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
424
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
425
|
+
*/
|
|
426
|
+
export const productsClassifiedsSeedData = _rawproductsClassifiedsSeedData.map(withProductSearchTxt);
|
|
@@ -1,2 +1,7 @@
|
|
|
1
1
|
import { ProductDocument } from "../features/products/schemas/firestore";
|
|
2
|
+
/**
|
|
3
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
4
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
5
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
6
|
+
*/
|
|
2
7
|
export declare const productsDigitalCodesSeedData: Partial<ProductDocument>[];
|
|
@@ -17,10 +17,11 @@
|
|
|
17
17
|
* @tag consumers:seed/index.ts,seed/runner.ts
|
|
18
18
|
* @tag sideEffects:none
|
|
19
19
|
*/
|
|
20
|
+
import { withProductSearchTxt } from "./_helpers/product-search-txt";
|
|
20
21
|
import { PRODUCT_FIELDS } from "../constants/field-names";
|
|
21
|
-
import {
|
|
22
|
+
import { buildSearchTxt } from "../utils/search-txt";
|
|
22
23
|
import { seedExtMedia } from "./_helpers/media";
|
|
23
|
-
|
|
24
|
+
const _rawproductsDigitalCodesSeedData = [
|
|
24
25
|
{
|
|
25
26
|
id: "digitalcode-beyblade-x-app-starter-pack",
|
|
26
27
|
slug: "digitalcode-beyblade-x-app-starter-pack",
|
|
@@ -59,7 +60,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
59
60
|
tags: ["digital-code", "app-content"],
|
|
60
61
|
createdAt: new Date("2026-05-06"),
|
|
61
62
|
updatedAt: new Date("2026-05-06"),
|
|
62
|
-
|
|
63
|
+
searchTxt: buildSearchTxt([
|
|
64
|
+
"Beyblade X App — Starter Pack Code",
|
|
65
|
+
"Digital redemption code for the Beyblade X companion app.",
|
|
66
|
+
"Takara-Tomy",
|
|
67
|
+
"brand-takara-tomy",
|
|
68
|
+
["Beyblade X", "Spinning Tops"],
|
|
69
|
+
["digital-code", "app-content"],
|
|
70
|
+
]),
|
|
63
71
|
},
|
|
64
72
|
{
|
|
65
73
|
id: "digitalcode-beyblade-x-app-legendary-pack",
|
|
@@ -97,7 +105,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
97
105
|
tags: ["digital-code", "app-content"],
|
|
98
106
|
createdAt: new Date("2026-08-14"),
|
|
99
107
|
updatedAt: new Date("2026-08-19"),
|
|
100
|
-
|
|
108
|
+
searchTxt: buildSearchTxt([
|
|
109
|
+
"Beyblade X App — Legendary Pack Code (Partially Claimed)",
|
|
110
|
+
"Unlocks 3 legendary digital tops, most of the batch already claimed.",
|
|
111
|
+
"Takara-Tomy",
|
|
112
|
+
"brand-takara-tomy",
|
|
113
|
+
["Beyblade X", "Spinning Tops"],
|
|
114
|
+
["digital-code", "app-content"],
|
|
115
|
+
]),
|
|
101
116
|
},
|
|
102
117
|
{
|
|
103
118
|
id: "digitalcode-beyblade-burst-app-sold-out",
|
|
@@ -139,7 +154,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
139
154
|
tags: ["digital-code", "app-content", "limited-run"],
|
|
140
155
|
createdAt: new Date("2026-08-01"),
|
|
141
156
|
updatedAt: new Date("2026-08-10"),
|
|
142
|
-
|
|
157
|
+
searchTxt: buildSearchTxt([
|
|
158
|
+
"Beyblade Burst App — Anniversary Pack Code (Sold Out)",
|
|
159
|
+
"Limited-run anniversary code pack, every code claimed.",
|
|
160
|
+
"Beyblade",
|
|
161
|
+
"brand-beyblade",
|
|
162
|
+
["Beyblade Burst", "Spinning Tops"],
|
|
163
|
+
["digital-code", "app-content", "limited-run"],
|
|
164
|
+
]),
|
|
143
165
|
},
|
|
144
166
|
{
|
|
145
167
|
id: "digitalcode-beyblade-x-manual-tournament-pass",
|
|
@@ -180,7 +202,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
180
202
|
tags: ["digital-code", "tournament-grade"],
|
|
181
203
|
createdAt: new Date("2026-08-15"),
|
|
182
204
|
updatedAt: new Date("2026-08-15"),
|
|
183
|
-
|
|
205
|
+
searchTxt: buildSearchTxt([
|
|
206
|
+
"Beyblade X Regional Tournament — Digital Entry Pass",
|
|
207
|
+
"Digital entry pass, emailed manually by the organizer.",
|
|
208
|
+
"Takara-Tomy",
|
|
209
|
+
"brand-takara-tomy",
|
|
210
|
+
["Beyblade X", "Spinning Tops"],
|
|
211
|
+
["digital-code", "tournament-grade"],
|
|
212
|
+
]),
|
|
184
213
|
},
|
|
185
214
|
{
|
|
186
215
|
id: "digitalcode-beyblade-metal-app-classic-pack",
|
|
@@ -217,7 +246,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
217
246
|
tags: ["digital-code", "app-content"],
|
|
218
247
|
createdAt: new Date("2026-08-16"),
|
|
219
248
|
updatedAt: new Date("2026-08-16"),
|
|
220
|
-
|
|
249
|
+
searchTxt: buildSearchTxt([
|
|
250
|
+
"Beyblade Metal Fight App — Classic Pack Code",
|
|
251
|
+
"Unlocks the Metal Fight classic-era top roster.",
|
|
252
|
+
"Takara-Tomy",
|
|
253
|
+
"brand-takara-tomy",
|
|
254
|
+
["Beyblade Metal Fight", "Spinning Tops"],
|
|
255
|
+
["digital-code", "app-content"],
|
|
256
|
+
]),
|
|
221
257
|
},
|
|
222
258
|
{
|
|
223
259
|
id: "digitalcode-beyblade-burst-app-avatar-skins",
|
|
@@ -254,7 +290,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
254
290
|
tags: ["digital-code", "app-content", "cosmetic"],
|
|
255
291
|
createdAt: new Date("2026-08-17"),
|
|
256
292
|
updatedAt: new Date("2026-08-19"),
|
|
257
|
-
|
|
293
|
+
searchTxt: buildSearchTxt([
|
|
294
|
+
"Beyblade Burst App — Avatar Skin Bundle Code",
|
|
295
|
+
"Cosmetic-only code bundle, 8 exclusive player avatar skins.",
|
|
296
|
+
"Beyblade",
|
|
297
|
+
"brand-beyblade",
|
|
298
|
+
["Beyblade Burst", "Spinning Tops"],
|
|
299
|
+
["digital-code", "app-content", "cosmetic"],
|
|
300
|
+
]),
|
|
258
301
|
},
|
|
259
302
|
{
|
|
260
303
|
id: "digitalcode-beyblade-x-manual-coaching-session",
|
|
@@ -298,7 +341,14 @@ export const productsDigitalCodesSeedData = [
|
|
|
298
341
|
tags: ["digital-code", "coaching"],
|
|
299
342
|
createdAt: new Date("2026-08-18"),
|
|
300
343
|
updatedAt: new Date("2026-08-18"),
|
|
301
|
-
|
|
344
|
+
searchTxt: buildSearchTxt([
|
|
345
|
+
"1-on-1 Beyblade X Coaching Session — Digital Booking Code",
|
|
346
|
+
"30-minute 1-on-1 video coaching session, booking link emailed manually.",
|
|
347
|
+
"Takara-Tomy",
|
|
348
|
+
"brand-takara-tomy",
|
|
349
|
+
["Beyblade X", "Spinning Tops"],
|
|
350
|
+
["digital-code", "coaching"],
|
|
351
|
+
]),
|
|
302
352
|
},
|
|
303
353
|
{
|
|
304
354
|
// Pool drained, but `stockQuantity: 5` and `isSold: false`.
|
|
@@ -344,3 +394,9 @@ export const productsDigitalCodesSeedData = [
|
|
|
344
394
|
updatedAt: new Date("2026-08-24"),
|
|
345
395
|
},
|
|
346
396
|
];
|
|
397
|
+
/**
|
|
398
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
399
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
400
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
401
|
+
*/
|
|
402
|
+
export const productsDigitalCodesSeedData = _rawproductsDigitalCodesSeedData.map(withProductSearchTxt);
|
|
@@ -1,2 +1,7 @@
|
|
|
1
1
|
import { ProductDocument } from "../features/products/schemas/firestore";
|
|
2
|
+
/**
|
|
3
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
4
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
5
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
6
|
+
*/
|
|
2
7
|
export declare const productsLiveItemsSeedData: Partial<ProductDocument>[];
|
|
@@ -30,10 +30,11 @@
|
|
|
30
30
|
* @tag consumers:seed/index.ts,seed/runner.ts
|
|
31
31
|
* @tag sideEffects:none
|
|
32
32
|
*/
|
|
33
|
+
import { withProductSearchTxt } from "./_helpers/product-search-txt";
|
|
33
34
|
import { PRODUCT_FIELDS } from "../constants/field-names";
|
|
34
|
-
import {
|
|
35
|
+
import { buildSearchTxt } from "../utils/search-txt";
|
|
35
36
|
import { seedExtMedia } from "./_helpers/media";
|
|
36
|
-
|
|
37
|
+
const _rawproductsLiveItemsSeedData = [
|
|
37
38
|
{
|
|
38
39
|
id: "live-golden-retriever-puppy",
|
|
39
40
|
slug: "live-golden-retriever-puppy",
|
|
@@ -75,7 +76,14 @@ export const productsLiveItemsSeedData = [
|
|
|
75
76
|
tags: ["live-item"],
|
|
76
77
|
createdAt: new Date("2026-08-16"),
|
|
77
78
|
updatedAt: new Date("2026-08-16"),
|
|
78
|
-
|
|
79
|
+
searchTxt: buildSearchTxt([
|
|
80
|
+
"Golden Retriever Puppy — 6 Months, Vaccinated",
|
|
81
|
+
"Friendly, vaccinated Golden Retriever puppy from a verified breeder.",
|
|
82
|
+
"Beyblade Arena",
|
|
83
|
+
undefined,
|
|
84
|
+
[],
|
|
85
|
+
["live-item"],
|
|
86
|
+
]),
|
|
79
87
|
},
|
|
80
88
|
{
|
|
81
89
|
id: "live-bearded-dragon-juvenile",
|
|
@@ -116,7 +124,14 @@ export const productsLiveItemsSeedData = [
|
|
|
116
124
|
tags: ["live-item"],
|
|
117
125
|
createdAt: new Date("2026-08-17"),
|
|
118
126
|
updatedAt: new Date("2026-08-17"),
|
|
119
|
-
|
|
127
|
+
searchTxt: buildSearchTxt([
|
|
128
|
+
"Bearded Dragon — Juvenile, Captive-Bred",
|
|
129
|
+
"Healthy captive-bred bearded dragon, specialist courier transport only.",
|
|
130
|
+
"Beyblade Arena",
|
|
131
|
+
undefined,
|
|
132
|
+
[],
|
|
133
|
+
["live-item"],
|
|
134
|
+
]),
|
|
120
135
|
},
|
|
121
136
|
{
|
|
122
137
|
id: "live-bonsai-juniper-10yr",
|
|
@@ -158,7 +173,14 @@ export const productsLiveItemsSeedData = [
|
|
|
158
173
|
tags: ["live-item"],
|
|
159
174
|
createdAt: new Date("2026-08-18"),
|
|
160
175
|
updatedAt: new Date("2026-08-18"),
|
|
161
|
-
|
|
176
|
+
searchTxt: buildSearchTxt([
|
|
177
|
+
"Juniper Bonsai — 10 Years Trained",
|
|
178
|
+
"A 10-year trained juniper bonsai in a glazed ceramic pot.",
|
|
179
|
+
"Beyblade Arena",
|
|
180
|
+
undefined,
|
|
181
|
+
[],
|
|
182
|
+
["live-item"],
|
|
183
|
+
]),
|
|
162
184
|
},
|
|
163
185
|
{
|
|
164
186
|
// Sold live item. Keeps species / sex / jurisdiction populated so those
|
|
@@ -203,3 +225,9 @@ export const productsLiveItemsSeedData = [
|
|
|
203
225
|
updatedAt: new Date("2026-08-24"),
|
|
204
226
|
},
|
|
205
227
|
];
|
|
228
|
+
/**
|
|
229
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
230
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
231
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
232
|
+
*/
|
|
233
|
+
export const productsLiveItemsSeedData = _rawproductsLiveItemsSeedData.map(withProductSearchTxt);
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
* @tag sideEffects:none
|
|
21
21
|
*/
|
|
22
22
|
import { PRODUCT_FIELDS } from "../constants/field-names";
|
|
23
|
-
import {
|
|
23
|
+
import { buildSearchTxt } from "../utils/search-txt";
|
|
24
24
|
import { seedExtMedia } from "./_helpers/media";
|
|
25
25
|
const _rawPreordersSeedData = [
|
|
26
26
|
{
|
|
@@ -302,5 +302,9 @@ export const productsPreordersSeedData = _rawPreordersSeedData.map((p) => ({
|
|
|
302
302
|
mainImage: p.images?.[0] ?? "",
|
|
303
303
|
...p,
|
|
304
304
|
listingType: "pre-order",
|
|
305
|
-
|
|
305
|
+
searchTxt: buildSearchTxt([
|
|
306
|
+
p.title, p.description, p.brand, p.brandSlug,
|
|
307
|
+
p.categoryNames, p.tags, p.features, p.condition,
|
|
308
|
+
p.specifications?.map((s) => `${s.name} ${s.value}`),
|
|
309
|
+
]),
|
|
306
310
|
}));
|
|
@@ -1,2 +1,7 @@
|
|
|
1
1
|
import { ProductDocument } from "../features/products/schemas/firestore";
|
|
2
|
+
/**
|
|
3
|
+
* Every record gains `searchTxt` here rather than inline, so a fixture added at
|
|
4
|
+
* the bottom of the array cannot ship without it — which is exactly how the
|
|
5
|
+
* sold/depleted fixture in this file ended up unsearchable.
|
|
6
|
+
*/
|
|
2
7
|
export declare const productsPrizeDrawsSeedData: Partial<ProductDocument>[];
|