Types: OrderStatus to OrdersScopeProps
The types of @poltura/theme-sdk/customer, OrderStatus to OrdersScopeProps.
On this page
import { … } from '@poltura/theme-sdk/customer';OrderStatus
Where an order is, as the shopper sees it.
type OrderStatus = 'pending' | 'processing' | 'shipped' | 'completed' | 'cancelled' | 'returned'OrderStatusFilter
The order list's status filter.
type OrderStatusFilter = OrderStatus | 'all'OrderSummary
An order as the order list shows it: enough for a card, without the totals breakdown.
type OrderSummary = Pick<Order, 'id' | 'number' | 'href' | 'placedAt' | 'status' | 'statusLabel' | 'currencyCode' | 'amountDue' | 'itemCount'> & {
readonly lines: readonly OrderSummaryLine[];
}OrderSummaryLine
A line of an order as the order list previews it.
type OrderSummaryLine = Pick<OrderLine, 'id' | 'title' | 'image' | 'quantity'>OrderTracking
One parcel's tracking.
carrierrequiredstringThe carrier's name.
urlrequiredstring | nullThe carrier's tracking page, or null.
coderequiredstringThe tracking code.
OrdersRequest
Which page of the order list to load.
pagenumberThe page number, from 1. Defaults to 1.
limitnumberHow many items a page holds, at most 100. Defaults to the store's page size.
statusOrderStatusFilterKeeps only the orders in this status among the page's orders; every order by default.
PaymentStatus
Where an order's payment is.
type PaymentStatus = 'pending' | 'authorized' | 'paid' | 'refunded' | 'partiallyRefunded' | 'failed'AddressCardProps
Props of AddressCard.
addressrequiredAddressThe address to show.
onEdit() => voidCalled by the edit button; without it the button is hidden.
onRemove() => voidCalled by the delete button; without it the button is hidden.
classNamestringClasses added to the card.
AddressFormProps
Props of AddressForm.
addressAddressThe address to change, or omitted for a new one.
onSubmitrequired(input: AddressInput) => Promise<void>Called with the entered address once it is valid.
onCancelrequired() => voidCalled by the cancel button.
submittingbooleanWhether the address is being saved, which disables the form.
AddressBookProps
Props of AddressBook.
classNamestringClasses added to the address book.
AccountNavProps
Props of AccountNav.
itemsrequiredreadonly AccountNavItem[]The entries to link to, usually the navigation of {@link useAccount}.
classNamestringClasses added to the grid.
OrderCardProps
Props of OrderCard.
orderrequiredOrderSummaryThe order to show; an order from the list or a full one.
classNamestringClasses added to the card.
OrderCardSkeletonProps
Props of OrderCardSkeleton.
classNamestringClasses added to the placeholder.
OrderFiltersProps
Props of OrderFilters.
valuerequiredOrderStatusFilterThe status the list is narrowed to.
onChangerequired(value: OrderStatusFilter) => voidCalled with the status the shopper picked.
classNamestringClasses added to the row of buttons.
OrderLinesProps
Props of OrderLines.
linesrequiredreadonly OrderLine[]The ordered lines.
classNamestringClasses added to the table.
OrderDetailProps
Props of OrderDetail.
idrequiredstringThe order's id.
classNamestringClasses added to the order page.
OrderDetailScopeProps
Props of OrderDetailScope.
idrequiredstringThe order's id.
fallbackReactNodeDrawn while the order loads.
childrenrequiredReactNodeThe order's parts, such as {@link OrderSummaryHeader} and {@link OrderItems}.
MarketingConsentToggleProps
Props of MarketingConsentToggle.
classNamestringClasses added to the toggle.
AuthInputProps
Props of AuthInput.
formrequiredAuthFormStateThe form the field belongs to.
fieldrequiredAuthFieldThe field to draw.
labelstringOverrides the label, which defaults to the field's name in the page language.
placeholderstringOverrides the placeholder.
labelAsideReactNodeDrawn on the label's line, at the end, for example a forgot-password link.
childrenReactNodeDrawn under the field and its error, for example hints about the address.
classNamestringClasses added to the field.
AuthSubmitProps
Props of AuthSubmit.
formrequiredAuthFormStateThe form to send.
labelstringOverrides the label, which defaults to the form's action in the page language.
disabledbooleanKeeps the button disabled besides while the form is sending.
classNamestringClasses added to the button.
AuthErrorProps
Props of AuthError.
formrequiredAuthFormStateThe form whose error to show.
classNamestringClasses added to the message.
PasskeySignInProps
Props of PasskeySignIn.
formrequiredAuthFormStateThe sign-in form whose email field names the account, and which shows the failure as its error.
classNamestringClasses added to the button.
SocialSignInProps
Props of SocialSignIn.
formrequiredAuthFormStateThe form that shows a provider's failure as its error.
providersreadonly string[]Limits the providers to these ids; every enabled provider by default.
classNamestringClasses added to the block.
EmailCodeStepProps
Props of EmailCodeStep.
classNamestringClasses added to the step.
AuthFieldsProps
Props of AuthFields.
classNamestringClasses for a box around the form; omit to place it with no box of its own.
BusinessSignUpFieldsProps
Props of BusinessSignUpFields.
formrequiredAuthFormStateThe registration form the company details belong to.
classNamestringClasses added to the fields.
OrdersScopeProps
Props of OrdersScope.
ordersrequiredQueryResult<OrderPage>The page of orders, as {@link useOrders} answers it.
childrenrequiredReactNodeWhat draws inside, usually the order history region.