remove unsecure content from modals-wrapper

It does come from vendor\magento\module-customer\view\frontend\web\template\authentication-popup.html. Since this is a knockout.js template file, you will have to delete your static content and then re-deploy (if you are in production mode) in order for changes to come through (clearing browser cache is also necessary sometimes). Instead of editing the file directly, you should copy it to your theme in here: app/design/frontend/{Vendor}/{Theme}/Magento_Customer/web/template/authentication-popup.html in order to override it from your theme.

To delete the static content, run rm -rf pub/static/* var/view_preprocessed/* from magento root directory. In production mode you then run the static content deployment command.

As far as I can tell, this modal is used if 'guest checkout' is disabled and a customer who is not logged in clicks on 'Proceed to Checkout' button in minicart or cart page. If guest checkout is enabled for your store, then you can remove it completely by disabling the layout block. To do this, create the file app/design/frontend/{Vendor}/{Theme}/Magento_Customer/layout/default.xml with this contents:

<?xml version="1.0"?>

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceBlock name="authentication-popup" remove="true"/>
    </body>
</page>

You must flush the cache after adding this file.


The thing is named authentication-popup in the layout xml. You can remove it with

<referenceBlock name="authentication-popup" remove="true"/>

in ../page_layout/1column.xml for example.

But I'm not really sure what it is used for either and if it is safe to remove it just like that.

This seems to be the file it is coming from:

../app/code/Magento/Customer/view/frontend/web/js/model/authentication-popup.js