Skip to main content

Questions tagged [swatches]

Alternative way of presenting the selection of options for configurable products

Filter by
Sorted by
Tagged with
1 vote
0 answers
16 views

color swatches and dropdown select on product page

Is there a way to get color swatches and a dropdown select for same attribute color on product view page?
user119803's user avatar
0 votes
0 answers
37 views

Visual swatch render as low resolution

I have an issue with my product visual swatch. When my product has a swatch image, it works fine. but if my product did not have swatch picture. I set the attribute properties to Use Product Image ...
Patiphon Ongartittichai's user avatar
0 votes
3 answers
125 views

How to Override the swatch-renderer.js in Magento 2 Custom Theme?

I am trying to override the swatch-renderer.js file in my custom Magento 2 theme. I have created the required directories and the custom JavaScript file but it doesn't seem to work. Here is what I ...
Ankush Lodhi's user avatar
0 votes
1 answer
56 views

Possible to use Advanced Pricing with Swatches/Configurable Product?

I work within a B2B environment and would love to use swatches for colors/sizes of things (so I don't need to have 4 separate product pages for 4 skus, but they can all be accessed on one page), but ...
ne0nlight's user avatar
0 votes
0 answers
56 views

How set limit of product's swatches on category listing page in magento246

How to set limit of product's swatches on category listing page. I have to show 5 swatches of the product on category listing page. I have tried below code but that's code working only 5 swatches of ...
Keval Chauhan's user avatar
0 votes
0 answers
27 views

Don't showing color swatches on category listing page in magento246

In magento246 color visual swatch working fine on product listing page.But,not showing on Category listing page...https://prnt.sc/78yEvqLYlx42 So, how to showing color visual swatch on category page.
Keval Chauhan's user avatar
0 votes
1 answer
155 views

Compilation from source: LESS file is empty:

I have upgraded my magento version from 2.4.0 to 2.4.6-p3 and in exceptions.log file i am continuously getting one error i.e main.CRITICAL: Magento\Framework\View\Asset\ContentProcessorException: ...
Tisha Jhanwar's user avatar
0 votes
1 answer
376 views

How to create custom Text Swatch product attribute using Data Patch in Magento 2

This code only saves the value (description). But I want to save values in ADMIN and DESCRIPTION both, can anyone help me here: private function addVisualSwatchAttribute() { /** @...
Hafiz Arslan's user avatar
0 votes
1 answer
29 views

How to copy size data from admin fields to swatch fields

I like to use the plain-size data as a text swatch in the size attribute. This size data is available in the admin fields. We have too many articles to enter the swatch data manually. I know there ...
Eeltje's user avatar
  • 1
0 votes
1 answer
373 views

Magento 2 Import Visual Swatch and Text Swatch Attribute Options Programatically

I have an attribute with attribute ID 'color'. Which has options with visual swatches. and another attribute with ID 'material' which has options with Text swatches. Now for the 'color' attribute I ...
m2dev's user avatar
  • 83
1 vote
1 answer
452 views

Magento 2.4.4: How to get Configurable child product id using Swatch option

How can I get the child product Id of Configurable product on selecting swatch option. I have used following code <script type="text/javascript"> requirejs(['jquery','underscore'], ...
Divya Rawat's user avatar
0 votes
1 answer
393 views

Magento 2 how to hide swatch on configurable product if it is out of stock?

I don't use MSI and i want so that swatches that are not available are hidden on the configurable product. How can this be done?
David Young's user avatar
2 votes
1 answer
672 views

How to disable "Add to Cart" and Quantity button if product is out of Stock?

I want to disable add to cart and qty option if product is out of stock, but i also want to show price and swatches of the products and the swatches should be clickable and price should be changeable ...
Afzel Arshad's user avatar
1 vote
1 answer
3k views

Magento 2 Product Salable Quantity shows 0 even if Qty is greater than 0

The products Salable Quantity of Simple products shows zero(0). But its Quantity is greater than zero (>0). Due to this product swatches are not showing correctly on the front end. Magento admin ...
IntraPersonalLearner's user avatar
0 votes
1 answer
159 views

Magento 2 swatches

I'm not good at Magento coding, so bear with me. I want to expose swatches for products with quantity 0 in the product list (changing the text with a ligther color with CSS for example) example: I'm ...
kray's user avatar
  • 3
0 votes
2 answers
481 views

Pass Simple product id along with the swatch options attribute in swatch renderer .js magento 2.4

We get swatch options by swatch renderer .js file. I want to pass the product id of the simple product along with the swatch option. Please see attached screenshot. I want to pass a simple product id ...
Nicola Smith's user avatar
1 vote
0 answers
147 views

How to show all images in configurable product before user has selected an option

It is very comfortable to the user navigate between all images product before select an option, but its confusing show all images when user has an option selected. I'm looking for a way to show all ...
jefferson's user avatar
-1 votes
1 answer
773 views

How to make round border with gap in swatch in css?

I have to make orange border of swatches like below image I made round swatches in magneto 2.4 and it look like below image My css code .swatch-option{border-radius:50%;min-width: 18px;width: 18px !...
Niraj Patel's user avatar
0 votes
1 answer
794 views

Configurable product with image swatch only on product page

Is it possible to show image swatches only on product page, and on category pages, related, upsell sliders to stay default color swatches. By default magento configuration its colors or image swatches ...
Alek Pangos's user avatar
2 votes
0 answers
191 views

Uncaught TypeError: $(...).AddFotoramaVideoEvents is not a function magento 2.3.6

I am facing this uncaught type error in swatch-renderer.js on listing page in magento 2.3.6 Till now i have tried 2 solutions but no luck: 1: added following lines catalog_category_view.xml <...
Umair Nasir Ahmad's user avatar
0 votes
0 answers
916 views

Product images not changing on swatches click on product listing pages

I am trying to change configurable product images on clicking swatches for product listing pages. But it is not working. It is working fine for product details page. Product detail page It is working ...
Rajeev Singh's user avatar
0 votes
1 answer
821 views

Clicking on color swatch, images are not loading on product listing page in magento 2.3.3

I have added color swatches for my Configurable products. On product detail page when we click on color swatches the product images gets changed properly. But this does not work fine on category pages....
Nafsss's user avatar
  • 758
0 votes
1 answer
97 views

Duplicate size swatches on some product pages

I've got something strange going on here and I can't pinpoint where the problem is. On some of the products pages I am getting duplicate size swatches What could be causing this issue? Could it be a ...
AdRock's user avatar
  • 111
0 votes
1 answer
409 views

Gallery image(thumbnails) not changing on visual swatch Magento 2.4.1

Is there any way to change the Gallery(thumbnail) image on visual swatch, currently only the base image get changed, I need to replace all the gallery image with selected product images
amith lal's user avatar
  • 790
1 vote
1 answer
133 views

Swatch on listing page but image on Product Page

First time posting here. Magento 2.4.0 I am trying to show color swatches on the product listing page but an image of the configurable products on the product page. By selecting use product image as ...
Phil Bradbury's user avatar
2 votes
2 answers
584 views

Magento2 override Magento_Swatches::product/listing/renderer.phtml

Magento2 how I am supposed to override renderer.phtml of module swatches? I have already tried Magento_Swatches::product/listing/renderer.phtml, but doesn't seem to be working? Any advice will be ...
Arjun's user avatar
  • 3,606
1 vote
2 answers
2k views

How to add swatch data in Layered navigation aggregations in graphql?

How to add swatch data in Layered navigation aggregations in Graphql? Magento provides swatch data to filters [LayerFilter] but this is DEPRECATED so we use aggregations for the filter. Below query is ...
Devidas's user avatar
  • 3,378
2 votes
1 answer
274 views

Magento 2.3.2 Single color variation auto selected on product list page

Magento 2.3.2 Single color variation auto selected on product list page, i have added this code in swatch-render.js after container append but it is selecting on all products instead of selecting only ...
Shaikh007's user avatar
1 vote
0 answers
286 views

Magento 2 "More" button on poduct listing page

I want more button next to swatches image and on click of more, it will redirect to the product details page
Akshay Kamble's user avatar
1 vote
0 answers
190 views

Magento 2: 404 for productpage image when click on swatch option

i have used the swatch option for configurable product and each of this color swatch product image are different for that associate products. I have already assign different different image for this ...
Dhaval Vaghela's user avatar
2 votes
0 answers
1k views

Magento 2 Create Product Swatch Attribute via API

Is it possible to create a swatch attribute via the API endpoint? Swatch product attributes are seemingly created programatically by setting swatch_input_type data to the attribute, as demonstrated ...
Liam Toohey's user avatar
1 vote
1 answer
72 views

How to hide the bubble when placing the cursor on option-label?

I wish to hide this information, because it is useless :
Thomas's user avatar
  • 83
0 votes
1 answer
2k views

Magento 2 : How to get swatch attribute label

I have an attribute "brand" with type Swatch. I have created many brands as an option in this attribute. I want to filter brands label which are starts with a particular letter (ex. A or B or C).
user88667's user avatar
1 vote
2 answers
3k views

Magento 2 combine two functionality s using a single mixin js file?

I would like to override Magento_Swatches/js/swatch-renderer.js file using mixins concept. I would like to club two functionalities in a single file. here is the code I have written please Note 2nd ...
Nagaraju Kasa's user avatar
1 vote
1 answer
2k views

Magento 2.3: How to set the default swatch selection pro-grammatically on product listing page?

I want to implement the selection of swatch options in a way that by default it should be selected 2nd swatch on listing pages. Attribute name is color. I looked over the following Blocks but not ...
Softec's user avatar
  • 2,103
1 vote
0 answers
407 views

Magento 2 - PHP Error After Saving Any Attribute

I am working on a Magento 1 to 2 migration and, after migrating data from 1 to 2, I am receiving an error when attempting to save or create an attribute, and when attempting to load the category and ...
Marisa's user avatar
  • 330
1 vote
1 answer
802 views

Text swatch value for multi store view showing wrong on frontend [ Magento 2.3.3 Enterprise Edition]

Have a look at below. Did anyone get the solution for this? Why product text swatch display admin swatch value instead of specific store value? Magento EE [2.3.3] Steps to reproduce: Create 2 ...
Roshan Rakesh Yadav's user avatar
2 votes
1 answer
2k views

Magento 2: how to get swatch options in custom product list on detail page?

I added my custom product list in detail page, the collection is properly displaying but now I want to display swatches in that list. is there any way to make it possible?
quickshiftin's user avatar
1 vote
1 answer
4k views

How to display Swatches into product list page into custom modules with add to cart functionality

How to display Swatches into the product list page into custom modules with add to cart functionality. We need to display properly selected options with the configuration product into cart.
Ravi Dudhara's user avatar
1 vote
1 answer
660 views

Magento 2.3 - Swatches Helper override

I'm trying to override a function in the Helper of the Swatches module of Magento 2. The function resides in the Data.php file. As some of you may know in specific versions of Magento 2 the text ...
Hendrik M.'s user avatar
1 vote
0 answers
148 views

How to dynamically change attribute value depending on the selected swatch or size?

I have a table in which I want to display product attribute data there, depending on the selected size or swatch. So that the value of the attributes in the table changes dynamically How to ...
Pavel Ivatsko's user avatar
0 votes
0 answers
362 views

Magento 2: swatch images loading ONLY thumbnails

I'm using Magento 2.3.3 and I have a very annoying problem with the swatches. When I click on size/color, the picture will show the standard placeholder, but if I take a look at the json, the picture ...
Gerardo Siano's user avatar
0 votes
0 answers
219 views

Magento 2 swatches problem

I have a very very annoying problem with Magento 2.3.3. I have a product with size and color attributes. If I inspect the code, I will see ALL the values: Indeed in "Magento_Swatches/js/swatch-...
Gerardo Siano's user avatar
0 votes
1 answer
208 views

Swatches on mobile not working

I have a problem with my site. When i select a swatch on mobile, the price of the product doesn't change. This is only a problem on the mobile version of the site and not present on the desktop ...
Wouter Stulp's user avatar
0 votes
0 answers
862 views

Magento 2: this.options.jsonConfig.mappedAttributes is undefined

Configurable products are not changing the pictures while selecting attributes like size or color. I really don't know how to fix this problem. It is two days now and I still facing the same issue. ...
Gerardo Siano's user avatar
0 votes
0 answers
690 views

Magento 2: configurable product doesn't update image on select of attribute

I know this is probably a duplicated, but I read ALL the posts about this issue and I still didn't figure it out. So, I have attribute size (dropdown) and attribute color (swatches). What I want is ...
Gerardo Siano's user avatar
0 votes
0 answers
739 views

Getting TypeError: $(...).AddFotoramaVideoEvents is not a function in magento 2.3.3

The image gallery is not loading on product detail page getting an error like Uncaught TypeError: $(...).AddFotoramaVideoEvents is not a function at $.<computed>.<computed>....
AjayKr's user avatar
  • 145
1 vote
0 answers
21 views

Magento2 Custom Product Type has no Swatch Image

I have added custom product types that are based on the simple product and this works. However I don't get a swatch image option. I can set base, small_image and thumbnail but no swatch. What have I ...
Henry's Cat's user avatar
  • 2,045
1 vote
1 answer
400 views

Magento 2: Unable to resize the swatch image

view.xml: <image id="swatch_image_base" type="swatch_image"> <width>500</width> <height>600</height> </image> <...
Rahul Singh's user avatar
  • 1,650
0 votes
1 answer
681 views

How magento 2.3 generates swatch images?

I want to resize default generated swatch images but upon doing that swatch images get blurred. So my question is, how to resize Magento swatch so that it will look nice? I have tried modifying ...
AjayKr's user avatar
  • 145

1
2 3 4 5 6