Documentation
Feedback
Guides
VTEX IO Apps

VTEX IO Apps
VTEX IO Apps
Shipping Option Components
Official extension
Version: 1.9.0
Latest version: 1.9.0

{"base64":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAABCAIAAAB2XpiaAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAFUlEQVR4nGPg4+Mz1Nfjl5T7f2c+AAzxA3lptuDWAAAAAElFTkSuQmCC","img":{"src":"https://img.shields.io/badge/all_contributors-0-orange.svg?style=flat-square","width":110,"height":20,"type":"svg"}}

The Shipping Option Components app is available only for stores using Delivery Promises. This feature is in closed beta, which means that only selected customers can access it. If you are interested in implementing it in the future, please contact our Support team.

For more information on setting up Delivery Promise components on Store Framework, see the developer documentation.

The Shipping Option Components app exports a component that aims to allow you to filter store products by location or pickup point.

{"base64":"  ","img":{"width":800,"height":392,"type":"gif","mime":"image/gif","wUnits":"px","hUnits":"px","length":3159719,"url":"https://github-production-user-asset-6210df.s3.amazonaws.com/15989443/424115986-6f334e28-fd01-42e9-a536-64eb9742e70c.gif?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20251010%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20251010T210518Z&X-Amz-Expires=300&X-Amz-Signature=765fd7119c7dcc072a258b473c756612dbd022ef486564f963b15a3d49facb37&X-Amz-SignedHeaders=host"}}

Configuration

Adding the Shipping Option Components app to your theme dependencies

Add the shipping-option-components app to your theme dependencies in the manifest.json as shown below:


_10
"dependencies": {
_10
"vtex.shipping-option-components": "1.x"
_10
}

You can now use all blocks exported by the shipping-option-components app. See the full list below:

Block nameDescription
shipping-option-location-selectorRenders a set of components that allow users to add their location and/or select a store for pickup.

Adding Shipping Option Components blocks to the theme

Declare the shipping-option-location-selector block as a child block of your header block, exported by the store-header app. Example:


_20
"header.full": {
_20
"blocks": ["header-layout.desktop", "header-layout.mobile"]
_20
},
_20
_20
"header-layout.desktop": {
_20
"children": [
_20
"header-row#1-desktop",
_20
]
_20
},
_20
_20
"header-row#1-desktop": {
_20
"children": ["shipping-option-location-selector"],
_20
},
_20
_20
"shipping-option-location-selector": {
_20
"props": {
_20
"compactMode": true,
_20
"showLocationDetectorButton": true
_20
}
_20
},

shipping-option-location-selector props

Prop nameTypeDescriptionDefault value
callToActionenumDefines the type of overlay that opens when the page loads. Possible values: modal (modal that requires a postal code input), popover-input (popover for postal code input), popover-button (popover that opens with a button).popover-input
compactModebooleanDetermines whether the button displays its label. When true, the label is hidden, showing only its value.false
dismissiblebooleanControls whether the modal can be dismissed without entering a postal code. When set to false, the modal cannot be closed until a postal code is entered. Must be used along with callToAction to correctly set a blocking modal.true
shippingSelectionenumDefines the type of shipping option selector to be shown. Possible values: delivery-and-pickup (shows both options), only-pickup (shows only the pickup store selector).undefined
showLocationDetectorButtonbooleanWhen set to true, displays a location detector button that automatically detects the user's current location using geolocation API and sets the postal code based on their coordinates. The button appears in both the main component and location modal.false

Customization

In order to apply CSS customizations in this and other blocks, follow the instructions given in the recipe on Using CSS Handles for store customization.

CSS Handles
buttonLabel
buttonValue
buttonWrapper
deliveryModalButtonLabel
deliveryModalButtonLabelLimited
deliveryModalButton
deliveryPopover
locationDetectorButton
locationDetectorButtonContainer
locationDetectorButtonIcon
noPickupsStateContent
pickupItem
pickupItemSelected
popoverInputContainer
popoverPolygon
popoverPolygonContainer
popoverPolygonSvg
postalCodeHelpLink
postalCodeInputClearButton
postalCodeInputContainer
shippingButtonContainer
shippingMethodModalOptions
shippingOptionButton
shippingOptionButtonSelected
See also
VTEX App Store
VTEX IO Apps
AvailabilityBadges
VTEX IO Apps
Was this helpful?