define(
    [
        'jquery',
        'Magento_Ui/js/modal/modal'
    ], function ($, modal) {
        'use strict';

        var mixin = {
            /** Show login popup window */
            showModal: function () {
                $(this.modalWindow).modal('openModal');

                // Init floating labels plugin
                setTimeout(function(){
                    new window.FloatLabels('.block-authentication .form', {
                        style: 1
                    });
                }, 200);
            }
        };

        return function (target) {
            target.showModal = mixin.showModal;
            return target;
        };
    }
);