Seller Card Pages

Two routes serve the card product. Which one a supplier lands on is decided by SellerCardListGuard.

Routing decision

canActivate(): Observable<boolean | UrlTree> {
    this.store.dispatch(loadPaymentMethods());
    this.store.dispatch(loadAirwallexCards());

    return combineLatest([
        this.store.pipe(select(selectIsPaymentMethodsLoaded)),
        this.store.pipe(select(selectPaymentsMethodLoading)),
        this.store.pipe(select(selectAirwallexCardsLoaded)),
    ]).pipe(
        filter(([loaded, loading, awxLoaded]) => loaded && !loading && awxLoaded),   (1)
        take(1),
        withLatestFrom(
            this.store.pipe(select(selectPcardsPaymentMethods)),
            this.store.pipe(select(selectHasAirwallexCards)),
        ),
        map(([_, methods, hasAirwallexCards]) => {
            const hasPcards = isArray(methods) && !isEmpty(methods);
            if (hasPcards || hasAirwallexCards) { return true; }
            return this.router.parseUrl('newcard');                                  (2)
        }),
    );
}
1 The guard waits until both card sources have settled, so it never routes on a half-loaded picture.
2 No cards from either issuer → the ordering funnel.
/seller-card
    ├─ has Marqeta p-cards or Airwallex cards ──▶ SellerCardListComponent
    └─ has neither ─────────────────────────────▶ redirect to /newcard

/seller-card — the list page

SellerCardModule → SellerCardPage → SellerCardListComponent.

Imports and composition:

SellerCardsModule

The seller-cards widget.

SellerCardsPanelModule

The unified "Your Cards" panel rendering both issuers.

CardTransactionsPageModule.forRoot({ noRowsMessage: 'SELLER_CARD.GRID_NO_ROWS_TEXT' })

Embedded transaction grid with card-specific empty-state copy.

ReportsCommonModule

Shared report scaffolding.

IconListModule, DynamicFieldModule, PybSkeletonModule

Presentation.

Card operations are routed by provider. UnifiedSupplierCard.raw carries the original provider model, so the page dispatches to the Marqeta or Airwallex service accordingly:

Action Marqeta Airwallex

Block

SellerCardBlockService

AirwallexCardBlockService

Unblock

SellerCardUnblockService

AirwallexCardUnblockService

View details

SellerCardViewService

AirwallexCardViewService

Activate

SellerCardActivateService

AirwallexCardService.activateCard()

Every one of them requires a passed 2FA challenge — see Seller Card.

Guards in this folder

SellerCardListGuard

Routes to /newcard when the supplier holds no cards.

ActiveUserGuard

Redirects to /newcard when supplierStatus !== Active.

/newcard — the ordering funnel

NewCardModule (views/pages/newcard/).

newcard.page.ts

The ordering page.

newcard-wrapper/

Layout shell.

newcard-perks/

Card benefits presentation.

newcard.constants.ts

Page copy and option constants.

shipping-address.constants.ts / .interface.ts

Physical-card delivery address.

Backed by the cardOrder slice:

loadCardProviders
  → loadCardProvidersSuccess   which CardProvider / CardFormFactor combinations are available
  → supplier picks provider + form factor
  → (Airwallex only) accept cardholder terms → AirwallexCardService.saveConsent()
  → (physical only) shipping address + optional expedite
  → orderCard → AirwallexCardService.newCard()
  → orderCardSuccess
export enum CardProvider   { Marqeta = 'marqeta', Airwallex = 'airwallex' }
export enum CardFormFactor { Physical = 'PHYSICAL', Virtual = 'VIRTUAL' }

Airwallex consent must be recorded before the order is placed. The new-card page reads getConsentStatus() and only shows the consent checkbox when cardholder_terms_accepted is false. If saveConsent() fails, the order must not proceed.

Request shaping differs by issuer — recipient_address and expedite_card are only sent for issuers that ship a physical card; Airwallex uses the cardholder address already on file.

/reports/card-transactions

Standalone transaction report.

widgets/seller-cards/

Dashboard summary card.

widgets/seller-cards-panel/

The unified card panel.

components/card-visual/, components/pcard/, components/awx-card/

Card artwork.

modals/seller-card-activate-modal/

Marqeta activation.

modals/seller-card-order-modal/

Order or replace.

modals/seller-card-block-modal/, …-unblock-modal/

Block and unblock confirmations.

modals/seller-card-view-modal/, modals/airwallex-card-view-modal/

Reveal card details.

modals/seller-card-transition-modal/

Marqeta → Airwallex migration.

modals/airwallex-pcard-terms-modal/

Provider terms acceptance.

Full business rules: Seller Card.