<?php
/**
 * Copyright © Magento, Inc. All rights reserved.
 * See COPYING.txt for license details.
 */

// @codingStandardsIgnoreFile

/**
 * @var \Magento\Theme\Block\Html\Header\Logo $block
 */
?>
<?php
$helper = $this->helper('Codazon\ThemeLayoutPro\Helper\Data');
if ($logo = $helper->getConfig('themelayoutpro/header/logo')) {
    $logo = $helper->getMediaUrl('codazon/logo/' . $logo); 
} else {
    $logo = $block->getLogoSrc();
}
$smallLogo = $helper->getConfig('themelayoutpro/header/small_logo');
$smallLogo = $smallLogo ? $helper->getMediaUrl('small_logo/' . $smallLogo) : $logo;
$logoWidth = (int) $helper->getConfig('themelayoutpro/header/logo_width');
$logoHeight = (int) $helper->getConfig('themelayoutpro/header/logo_height');
?>

<?php $storeName = $block->getThemeName() ? $block->getThemeName() : $block->getLogoAlt();?>
<span data-action="toggle-nav" class="action nav-toggle"><span><?= /* @escapeNotVerified */ __('Toggle Nav') ?></span></span>
<a class="logo" href="<?= $block->getUrl('') ?>" title="<?= /* @escapeNotVerified */ $storeName ?>">
    <img class="main-logo hidden-xs" src="<?= /* @escapeNotVerified */ $logo ?>"
         alt="<?= /* @escapeNotVerified */ $block->getLogoAlt() ?>"
         <?= $logoWidth ? 'width="' . $logoWidth . '"' : '' ?>
         <?= $logoHeight ? 'height="' . $logoHeight . '"' : '' ?>
    />
    <img class="small-logo visible-xs" src="<?= /* @escapeNotVerified */ $smallLogo ?>"
         alt="<?= /* @escapeNotVerified */ $block->getLogoAlt() ?>"
    />
</a>
