:::: MENU ::::

magento 2 remove tool tip icon checkout page

Recent QuestionsCategory: Magento 2 Questionsmagento 2 remove tool tip icon checkout page
Kamran asked 2 months ago

Remove tooltip icon in checkout page.

1) Remove near email
1) Remove near phone number

1 Answers
Best Answer
qaisarsatti Staff answered 2 months ago

Create plugin for Checkout\LayoutProcessor

app/code/QaisarSatti/HelloWorld/etc/frontend/di.xml

<?xml version="1.0"?>

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\Checkout\Block\Checkout\LayoutProcessor">
        <plugin name="helloworld-checkout-process" type="QaisarSatti\HelloWorld\Plugin\LayoutProcessorPlugin" />
    </type>
</config>

Now create the LayoutProcessorPlugin.php file on following location

app/code/QaisarSatti/HelloWorld/Plugin/LayoutProcessorPlugin.php

namespace QaisarSatti\HelloWorld\Plugin;

use Magento\Checkout\Block\Checkout\LayoutProcessor;

class LayoutProcessorPlugin
{
   
    public function afterProcess(
        LayoutProcessor $subject,
        $jsLayout
    ) {
   
      //Remove tooltip for email
        unset($jsLayout['components']['checkout']['children']['steps']['children']['shipping-step']
            ['children']['shippingAddress']['children']['shipping-address-fieldset']['children']['email']['config']['tooltip']);
        //Remove tooltip for telephone
        unset($jsLayout['components']['checkout']['children']['steps']['children']['shipping-step']
            ['children']['shippingAddress']['children']['shipping-address-fieldset']['children']['telephone']['config']['tooltip']);
     
     


        return $jsLayout;
    }
}