Documentation
Feedback
Guides
VTEX IO Apps

VTEX IO Apps
Product Brand
vtex.store-components
Version: 3.150.0
Latest version: 3.178.1

This page is about version 3.150.0 of the app, which is not the most recent version. The latest stable version is 3.178.1.

The ProductBrand is a VTEX block that displays either the name or the logo of a product's brand.

{"base64":"  ","img":{"width":2854,"height":1578,"type":"png","mime":"image/png","wUnits":"px","hUnits":"px","length":661337,"url":"https://user-images.githubusercontent.com/52087100/70259346-bb081f80-176c-11ea-84db-5785c45829ce.png"}}

Configuration

  1. Import the vtex.store-components app to your theme's dependencies in the manifest.json, for example:

_10
"dependencies: {
_10
"vtex.store-components": "2.x"
_10
}

  1. Add the product-brand block to any block below store.product(Product template). For example:

_15
"store.product": {
_15
"children": [
_15
"flex-layout.row#product",
_15
]
_15
},
_15
"flex-layout.row#product": {
_15
"children": [
_15
"product-brand"
_15
]
_15
},
_15
"product-brand": {
_15
"props": {
_15
"displayMode": "text"
_15
}
_15
},

Configuration

Prop nameTypeDescriptionDefault value
displayModestringYou should choose between logo or text. This will define if the product brand will be displayed by name or logo.logo
fallbackToTextbooleanThis prop should only be used when displayMode is set to logo. It defines what should be done when the Product Brand was set to display a brand logo but no image was registered in the VTEX admin's Catalog. This prop is set as true by default, allowing the logo to be replaced with the brand name in those scenarios. When set as false, the store will not show the brand name instead of the brand logo.true
loadingPlaceholderstringYou should choose between logo or text. This will define if the loading placeholder should have the size of the logo or the text.undefined
heightnumberIt sets the logo height. It should only be used when displayMode is set to logo.100
excludeBrandsarrayThe brand names or brand IDs listed in the array will never be displayed by the Brand component. It is usually useful to hide default or test brand names/logos on the store front.undefined
logoWithLinkboolean
{"base64":"  ","img":{"width":73,"height":20,"type":"svg","mime":"image/svg+xml","wUnits":"px","hUnits":"px","url":"https://img.shields.io/badge/-Deprecated-red"}}
Use withLink instead
false
withLinkenumDefines the scenarios in which the product brand should have a link that leads to its website. Possible values are: none (never includes the link), logo (includes the link whenever the brand logo is displayed), text (includes the link whenever the brand name is displayed), and logoAndText (includes the link whenever the brand logo or the brand name is displayed).none
brandNamestringThe brand name. If no value is declared, the product context should provide the data.undefined
brandIdnumberThe brand ID. If no value is declared, the product context should provide the data.undefined
classesCustomCSSClassesUsed to override default CSS handles. To better understand how this prop works, we recommend reading about it here. Note that this is only useful if you're using this block as a React component.undefined

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
productBrandContainer
productBrandName
productBrandLogo
productBrandLogoWrapper
productBrandLogoLink
productBrandNameLink
productBrandLogoSpacer
productBrandNameSpacer
See also
Vtex.store Components
VTEX IO Apps
VTEX App Store
VTEX IO Apps