2.3.3: How would I stop the anchor/scroll on the product details tabs?
-
29-03-2021 - |
Frage
I would like to prevent the horrible snapping of the product details tabs and can't seem to figure out where it is coming from? I tried removing the link in the details.phtml and it still snaps so I'm assuming it isn't an anchor and is some JS. Thanks.
For me the tabs have been converted into an accordion:
<div class="product data items" data-mage-init='{"accordion":{"openedState": "active", "collapsible": true, "active": "0", "multipleCollapsible": true, "animate": {"duration": 300}}}'>
<?php foreach ($detailedInfoGroup as $name) :?>
<?php
$html = $layout->renderElement($name);
if (!trim($html)) {
continue;
}
$alias = $layout->getElementAlias($name);
$label = $block->getChildData($alias, 'title');
?>
<div data-role="collapsible" class="allow">
<a href="#" data-toggle="trigger"><?= /* @noEscape */ $label ?></a>
</div>
<div data-role="content">
<?= /* @noEscape */ $html ?>
</div>
<?php endforeach;?>
</div>
Lösung
Looks like an issue with Magento 2.3.3 see Magento's GitHub Issue
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit magento.stackexchange