Skip to content

Latest commit

 

History

History
45 lines (31 loc) · 2.32 KB

ProductBrand.md

File metadata and controls

45 lines (31 loc) · 2.32 KB

Product Brand

Description

ProductBrand is a VTEX Component that shows either the name or the logo of the product's brand, when inserted in a Product context.

📢 Disclaimer: Don't fork this project; use, contribute, or open issue with your feature request.

Table of Contents

Usage

You should follow the usage instruction in the main README.

Then, add product-brand block into our app theme, as we do in our Product Details app.

Blocks API

This component has an interface that describes which rules must be implemented by a block when you want to use the ProductBrand.

  "product-brand": {
    "component": "ProductBrand"
  }

Configuration

Prop name Type Description
displayMode String You should choose between “logo” or “text”. This will define whether the product brand will be displayed by name or logo.
fallbackToText Boolean This prop should only be used when displayMode is set to logo. It defines what should be done when the Brand Component should have displayed a brand logo but no image was registered in the VTEX Catalog. This prop is set as true by default, allowing the logo to be replaced with the brand name in those cases. When set as false, the store will not show the brand name instead of the brand logo
height Number It sets the logo height. It should only be used when displaymode is set to “logo”.
excludeBrands Array The brand names or brand IDs that are listed in the array will never be displayed by the Brand component. It is usually useful to hide default brand names/logos or test brand names/logos on the store front.
logoWithLink boolean If the brand logo will have a link that leads to the store's brand page
brandName String The brand name. If this value is not passed, it will be obtained through the product context.
brandId Number The brand id. If this value is not passed, it will be obtained through the product context.

Styles API

🚧 🚧 🚧