<?php
use Twig\Environment;
use function Shopware\Core\Framework\Adapter\Twig\sw_get_attribute;
use function Shopware\Core\Framework\Adapter\Twig\sw_escape_filter;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
/* @EnderecoShopware6ClientStore/storefront/layout/meta.html.twig */
class __TwigTemplate_a453829c348ef5139a5ad4db65520160df2d322100959d19b1b7c52152429b60 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'layout_head_meta_tags' => [$this, 'block_layout_head_meta_tags'],
];
}
protected function doGetParent(array $context)
{
// line 2
return "@WbmTagManagerEcomm/storefront/layout/meta.html.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@EnderecoShopware6ClientStore/storefront/layout/meta.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@EnderecoShopware6ClientStore/storefront/layout/meta.html.twig"));
$this->parent = $this->loadTemplate("@WbmTagManagerEcomm/storefront/layout/meta.html.twig", "@EnderecoShopware6ClientStore/storefront/layout/meta.html.twig", 2);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 3
public function block_layout_head_meta_tags($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "layout_head_meta_tags"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "layout_head_meta_tags"));
// line 4
echo " <script>
if (undefined === window.EnderecoIntegrator) {
window.EnderecoIntegrator = {};
}
if (!window.EnderecoIntegrator.onLoad) {
window.EnderecoIntegrator.onLoad = [];
}
window.EnderecoIntegrator.countryCodeToNameMapping = JSON.parse('";
// line 12
echo sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 12), "countryCodeToNameMapping", [], "any", false, false, false, 12);
echo "');
window.EnderecoIntegrator.countryMapping = JSON.parse('";
// line 13
echo sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 13), "countryMapping", [], "any", false, false, false, 13);
echo "');
window.EnderecoIntegrator.countryMappingReverse = JSON.parse('";
// line 14
echo sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 14), "countryMappingReverse", [], "any", false, false, false, 14);
echo "');
window.EnderecoIntegrator.subdivisionCodeToNameMapping = JSON.parse('";
// line 16
echo sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 16), "subdivisionCodeToNameMapping", [], "any", false, false, false, 16);
echo "');
window.EnderecoIntegrator.subdivisionMapping = JSON.parse('";
// line 17
echo sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 17), "subdivisionMapping", [], "any", false, false, false, 17);
echo "');
window.EnderecoIntegrator.subdivisionMappingReverse = JSON.parse('";
// line 18
echo sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 18), "subdivisionMappingReverse", [], "any", false, false, false, 18);
echo "');
function enderecoInitAMS(prefix, config, cb) {
if (undefined !== window.EnderecoIntegrator.initAMS) {
var EAO = window.EnderecoIntegrator.initAMS(prefix, config);
if (cb) {
cb(EAO);
}
} else {
window.EnderecoIntegrator.onLoad.push(function () {
var EAO = window.EnderecoIntegrator.initAMS(prefix, config);
if (cb) {
cb(EAO);
}
});
}
}
function enderecoInitES(prefix, config) {
if (undefined !== window.EnderecoIntegrator.initEmailServices) {
window.EnderecoIntegrator.initEmailServices(prefix, config);
} else {
window.EnderecoIntegrator.onLoad.push(function () {
window.EnderecoIntegrator.initEmailServices(prefix, config);
});
}
}
function enderecoInitPS(prefix, config) {
if (undefined !== window.EnderecoIntegrator.initEmailServices) {
window.EnderecoIntegrator.initPersonServices(prefix, config);
} else {
window.EnderecoIntegrator.onLoad.push(function () {
window.EnderecoIntegrator.initPersonServices(prefix, config);
});
}
}
function enderecoSetConfigValues() {
window.EnderecoIntegrator.themeName = '';
window.EnderecoIntegrator.defaultCountrySelect = !!('";
// line 58
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 58), "defaultCountrySelect", [], "any", false, false, false, 58), "html", null, true);
echo "');
window.EnderecoIntegrator.defaultCountry = '";
// line 59
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 59), "defaultCountry", [], "any", false, false, false, 59), "html", null, true);
echo "';
window.EnderecoIntegrator.config.agentName = '";
// line 60
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 60), "enderecoAgentInfo", [], "any", false, false, false, 60), "html", null, true);
echo "';
window.EnderecoIntegrator.config.apiUrl = '";
// line 61
echo sw_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("bundles/enderecoshopware6clientstore/io.php"), "html", null, true);
echo "';
window.EnderecoIntegrator.config.apiKey = '";
// line 62
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 62), "enderecoApiKey", [], "any", false, false, false, 62), "html", null, true);
echo "';
window.EnderecoIntegrator.config.showDebugInfo = false;
window.EnderecoIntegrator.config.remoteApiUrl = '";
// line 64
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 64), "enderecoRemoteUrl", [], "any", false, false, false, 64), "html", null, true);
echo "';
window.EnderecoIntegrator.config.trigger.onblur = !!('";
// line 65
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 65), "enderecoTriggerOnBlur", [], "any", false, false, false, 65), "html", null, true);
echo "');
window.EnderecoIntegrator.config.trigger.onsubmit = !!('";
// line 66
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 66), "enderecoTriggerOnSubmit", [], "any", false, false, false, 66), "html", null, true);
echo "');
window.EnderecoIntegrator.config.ux.smartFill = false;
window.EnderecoIntegrator.config.ux.checkExisting = false;
window.EnderecoIntegrator.config.ux.resumeSubmit = !!('";
// line 69
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 69), "enderecoContinueSubmit", [], "any", false, false, false, 69), "html", null, true);
echo "');
window.EnderecoIntegrator.config.ux.useStandardCss = true;
window.EnderecoIntegrator.config.ux.showEmailStatus = false;
window.EnderecoIntegrator.config.ux.allowCloseModal = !!('";
// line 72
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 72), "enderecoAllowCloseIcon", [], "any", false, false, false, 72), "html", null, true);
echo "');
window.EnderecoIntegrator.config.ux.confirmWithCheckbox = !!('";
// line 73
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "endereco_config", [], "any", false, false, false, 73), "enderecoConfirmWithCheckbox", [], "any", false, false, false, 73), "html", null, true);
echo "');
window.EnderecoIntegrator.config.ux.changeFieldsOrder = true;
window.EnderecoIntegrator.config.splitStreet = false;
window.EnderecoIntegrator.countryMappingUrl = '';
window.EnderecoIntegrator.config.templates.primaryButtonClasses = 'btn btn-primary btn-lg';
window.EnderecoIntegrator.config.templates.secondaryButtonClasses = 'btn btn-secondary btn-lg';
window.EnderecoIntegrator.config.texts = {
popUpHeadline: '";
// line 80
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.popUpHeadline")));
echo "',
popUpSubline: '";
// line 81
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.popUpSubline")));
echo "',
mistakeNoPredictionSubline: '";
// line 82
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.mistakeNoPredictionSubline")));
echo "',
confirmMyAddressCheckbox: '";
// line 83
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.confirmMyAddressCheckbox")));
echo "',
notFoundSubline: '";
// line 84
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.notFoundSubline")));
echo "',
yourInput: '";
// line 85
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.yourInput")));
echo "',
editYourInput: '";
// line 86
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.editYourInput")));
echo "',
ourSuggestions: '";
// line 87
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.ourSuggestions")));
echo "',
useSelected: '";
// line 88
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.useSelected")));
echo "',
confirmAddress: '";
// line 89
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.confirmAddress")));
echo "',
editAddress: '";
// line 90
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.editAddress")));
echo "',
warningText: '";
// line 91
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.warningText")));
echo "',
popupHeadlines: {
general_address: '";
// line 93
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.general_address")));
echo "',
billing_address: '";
// line 94
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.billing_address")));
echo "',
shipping_address: '";
// line 95
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.texts.shipping_address")));
echo "',
},
statuses: {
email_not_correct: '";
// line 98
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.email_not_correct")));
echo "',
email_cant_receive: '";
// line 99
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.email_cant_receive")));
echo "',
email_syntax_error: '";
// line 100
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.email_syntax_error")));
echo "',
email_no_mx: '";
// line 101
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.email_no_mx")));
echo "',
building_number_is_missing: '";
// line 102
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.building_number_is_missing")));
echo "',
building_number_not_found: '";
// line 103
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.building_number_not_found")));
echo "',
street_name_needs_correction: '";
// line 104
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.street_name_needs_correction")));
echo "',
locality_needs_correction: '";
// line 105
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.locality_needs_correction")));
echo "',
postal_code_needs_correction: '";
// line 106
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.postal_code_needs_correction")));
echo "',
country_code_needs_correction: '";
// line 107
echo sw_escape_filter($this->env, $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("enderecoshopware6clientstore.statuses.country_code_needs_correction")));
echo "',
}
};
window.EnderecoIntegrator.activeServices = {
ams: true,
emailService: false,
personService: false
}
// Execute all function that have been called throughout the page.
window.EnderecoIntegrator.onLoad.forEach(function (callback) {
callback();
});
window.EnderecoIntegrator.ready = true;
(function() {
window.EnderecoIntegrator.\$formScanner = {
loop: null,
start: function() {
this.loop = setInterval( function() {
document.querySelectorAll('[name=\"endereco_data_marker\"][data-has-object=\"no\"]').forEach( function(MarkerElement) {
var formElement = MarkerElement.closest('form');
var formId = '';
if (formElement.getAttribute('data-endereco-ams-form-id')) {
formId = formElement.getAttribute('data-endereco-ams-form-id');
} else {
formId = (Math.floor(Math.random() * 100) * Date.now()).toString(16);
formElement.setAttribute('data-endereco-ams-form-id', formId);
}
if ('ams' === MarkerElement.value) {
var prefix = MarkerElement.getAttribute('data-used-prefix');
var countryCodeSelector = MarkerElement.getAttribute('data-country-code-selector');
var postalCodeSelector = MarkerElement.getAttribute('data-postal-code-selector');
var localitySelector = MarkerElement.getAttribute('data-locality-selector');
var streetFullSelector = MarkerElement.getAttribute('data-street-full-selector');
var subdivisionCodeSelector = MarkerElement.getAttribute('data-subdivision-code-selector');
var isAjax = false;
var EAO = window.EnderecoIntegrator.initAMS(
{
countryCode: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${countryCodeSelector}\"]`,
subdivisionCode: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${subdivisionCodeSelector}\"]`,
postalCode: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${postalCodeSelector}\"]`,
locality: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${localitySelector}\"]`,
streetFull: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${streetFullSelector}\"]`,
}, {
name: `ams_\${prefix}_\${formId}`,
addressType: 'general_address'
}
);
// If ajax, add click listener.
isAjax = 'true' === formElement.getAttribute('data-form-ajax-submit');
if (isAjax) {
formElement.querySelector('[type=\"submit\"]').addEventListener('click', function(e) {
if (EAO.util.shouldBeChecked()) {
e.preventDefault();
// Resume click after ac is done.
window.EnderecoIntegrator.submitResume = function() {
EAO.waitUntilReady().then( function() {
if(e.target.dispatchEvent(
new EAO.util.CustomEvent(
'click',
{
'bubbles': true,
'cancelable': true
}
)
)) {
e.target.click();
}
}).catch();
}
EAO.util.checkAddress().then().catch(function() {
EAO.waitUntilReady().then( function() {
if(e.target.dispatchEvent(
new EAO.util.CustomEvent(
'click',
{
'bubbles': true,
'cancelable': true
}
)
)) {
e.target.click();
}
}).catch();
});
return false;
}
});
}
}
MarkerElement.setAttribute('data-has-object', 'yes');
});
}, 1);
},
stop: function() {
}
}
window.EnderecoIntegrator.\$formScanner.start();
})();
}
function enderecoLoadAMSConfig() {
var \$interval = setInterval( function() {
if (!!window.EnderecoIntegrator.config) {
enderecoSetConfigValues();
clearInterval(\$interval);
}
}, 1);
}
</script>
";
// line 221
$this->displayParentBlock("layout_head_meta_tags", $context, $blocks);
echo "
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "@EnderecoShopware6ClientStore/storefront/layout/meta.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 413 => 221, 296 => 107, 292 => 106, 288 => 105, 284 => 104, 280 => 103, 276 => 102, 272 => 101, 268 => 100, 264 => 99, 260 => 98, 254 => 95, 250 => 94, 246 => 93, 241 => 91, 237 => 90, 233 => 89, 229 => 88, 225 => 87, 221 => 86, 217 => 85, 213 => 84, 209 => 83, 205 => 82, 201 => 81, 197 => 80, 187 => 73, 183 => 72, 177 => 69, 171 => 66, 167 => 65, 163 => 64, 158 => 62, 154 => 61, 150 => 60, 146 => 59, 142 => 58, 99 => 18, 95 => 17, 91 => 16, 86 => 14, 82 => 13, 78 => 12, 68 => 4, 58 => 3, 35 => 2,);
}
public function getSourceContext()
{
return new Source("{% sw_extends '@Storefront/storefront/layout/meta.html.twig' %}
{% block layout_head_meta_tags %}
<script>
if (undefined === window.EnderecoIntegrator) {
window.EnderecoIntegrator = {};
}
if (!window.EnderecoIntegrator.onLoad) {
window.EnderecoIntegrator.onLoad = [];
}
window.EnderecoIntegrator.countryCodeToNameMapping = JSON.parse('{{ page.endereco_config.countryCodeToNameMapping|raw }}');
window.EnderecoIntegrator.countryMapping = JSON.parse('{{ page.endereco_config.countryMapping|raw }}');
window.EnderecoIntegrator.countryMappingReverse = JSON.parse('{{ page.endereco_config.countryMappingReverse|raw }}');
window.EnderecoIntegrator.subdivisionCodeToNameMapping = JSON.parse('{{ page.endereco_config.subdivisionCodeToNameMapping|raw }}');
window.EnderecoIntegrator.subdivisionMapping = JSON.parse('{{ page.endereco_config.subdivisionMapping|raw }}');
window.EnderecoIntegrator.subdivisionMappingReverse = JSON.parse('{{ page.endereco_config.subdivisionMappingReverse|raw }}');
function enderecoInitAMS(prefix, config, cb) {
if (undefined !== window.EnderecoIntegrator.initAMS) {
var EAO = window.EnderecoIntegrator.initAMS(prefix, config);
if (cb) {
cb(EAO);
}
} else {
window.EnderecoIntegrator.onLoad.push(function () {
var EAO = window.EnderecoIntegrator.initAMS(prefix, config);
if (cb) {
cb(EAO);
}
});
}
}
function enderecoInitES(prefix, config) {
if (undefined !== window.EnderecoIntegrator.initEmailServices) {
window.EnderecoIntegrator.initEmailServices(prefix, config);
} else {
window.EnderecoIntegrator.onLoad.push(function () {
window.EnderecoIntegrator.initEmailServices(prefix, config);
});
}
}
function enderecoInitPS(prefix, config) {
if (undefined !== window.EnderecoIntegrator.initEmailServices) {
window.EnderecoIntegrator.initPersonServices(prefix, config);
} else {
window.EnderecoIntegrator.onLoad.push(function () {
window.EnderecoIntegrator.initPersonServices(prefix, config);
});
}
}
function enderecoSetConfigValues() {
window.EnderecoIntegrator.themeName = '';
window.EnderecoIntegrator.defaultCountrySelect = !!('{{ page.endereco_config.defaultCountrySelect }}');
window.EnderecoIntegrator.defaultCountry = '{{ page.endereco_config.defaultCountry }}';
window.EnderecoIntegrator.config.agentName = '{{ page.endereco_config.enderecoAgentInfo }}';
window.EnderecoIntegrator.config.apiUrl = '{{ asset('bundles/enderecoshopware6clientstore/io.php') }}';
window.EnderecoIntegrator.config.apiKey = '{{ page.endereco_config.enderecoApiKey }}';
window.EnderecoIntegrator.config.showDebugInfo = false;
window.EnderecoIntegrator.config.remoteApiUrl = '{{ page.endereco_config.enderecoRemoteUrl }}';
window.EnderecoIntegrator.config.trigger.onblur = !!('{{ page.endereco_config.enderecoTriggerOnBlur }}');
window.EnderecoIntegrator.config.trigger.onsubmit = !!('{{ page.endereco_config.enderecoTriggerOnSubmit }}');
window.EnderecoIntegrator.config.ux.smartFill = false;
window.EnderecoIntegrator.config.ux.checkExisting = false;
window.EnderecoIntegrator.config.ux.resumeSubmit = !!('{{ page.endereco_config.enderecoContinueSubmit }}');
window.EnderecoIntegrator.config.ux.useStandardCss = true;
window.EnderecoIntegrator.config.ux.showEmailStatus = false;
window.EnderecoIntegrator.config.ux.allowCloseModal = !!('{{ page.endereco_config.enderecoAllowCloseIcon }}');
window.EnderecoIntegrator.config.ux.confirmWithCheckbox = !!('{{ page.endereco_config.enderecoConfirmWithCheckbox }}');
window.EnderecoIntegrator.config.ux.changeFieldsOrder = true;
window.EnderecoIntegrator.config.splitStreet = false;
window.EnderecoIntegrator.countryMappingUrl = '';
window.EnderecoIntegrator.config.templates.primaryButtonClasses = 'btn btn-primary btn-lg';
window.EnderecoIntegrator.config.templates.secondaryButtonClasses = 'btn btn-secondary btn-lg';
window.EnderecoIntegrator.config.texts = {
popUpHeadline: '{{ \"enderecoshopware6clientstore.texts.popUpHeadline\"|trans|sw_sanitize|escape }}',
popUpSubline: '{{ \"enderecoshopware6clientstore.texts.popUpSubline\"|trans|sw_sanitize|escape }}',
mistakeNoPredictionSubline: '{{ \"enderecoshopware6clientstore.texts.mistakeNoPredictionSubline\"|trans|sw_sanitize|escape }}',
confirmMyAddressCheckbox: '{{ \"enderecoshopware6clientstore.texts.confirmMyAddressCheckbox\"|trans|sw_sanitize|escape }}',
notFoundSubline: '{{ \"enderecoshopware6clientstore.texts.notFoundSubline\"|trans|sw_sanitize|escape }}',
yourInput: '{{ \"enderecoshopware6clientstore.texts.yourInput\"|trans|sw_sanitize|escape }}',
editYourInput: '{{ \"enderecoshopware6clientstore.texts.editYourInput\"|trans|sw_sanitize|escape }}',
ourSuggestions: '{{ \"enderecoshopware6clientstore.texts.ourSuggestions\"|trans|sw_sanitize|escape }}',
useSelected: '{{ \"enderecoshopware6clientstore.texts.useSelected\"|trans|sw_sanitize|escape }}',
confirmAddress: '{{ \"enderecoshopware6clientstore.texts.confirmAddress\"|trans|sw_sanitize|escape }}',
editAddress: '{{ \"enderecoshopware6clientstore.texts.editAddress\"|trans|sw_sanitize|escape }}',
warningText: '{{ \"enderecoshopware6clientstore.texts.warningText\"|trans|sw_sanitize|escape }}',
popupHeadlines: {
general_address: '{{ \"enderecoshopware6clientstore.texts.general_address\"|trans|sw_sanitize|escape }}',
billing_address: '{{ \"enderecoshopware6clientstore.texts.billing_address\"|trans|sw_sanitize|escape }}',
shipping_address: '{{ \"enderecoshopware6clientstore.texts.shipping_address\"|trans|sw_sanitize|escape }}',
},
statuses: {
email_not_correct: '{{ \"enderecoshopware6clientstore.statuses.email_not_correct\"|trans|sw_sanitize|escape }}',
email_cant_receive: '{{ \"enderecoshopware6clientstore.statuses.email_cant_receive\"|trans|sw_sanitize|escape }}',
email_syntax_error: '{{ \"enderecoshopware6clientstore.statuses.email_syntax_error\"|trans|sw_sanitize|escape }}',
email_no_mx: '{{ \"enderecoshopware6clientstore.statuses.email_no_mx\"|trans|sw_sanitize|escape }}',
building_number_is_missing: '{{ \"enderecoshopware6clientstore.statuses.building_number_is_missing\"|trans|sw_sanitize|escape }}',
building_number_not_found: '{{ \"enderecoshopware6clientstore.statuses.building_number_not_found\"|trans|sw_sanitize|escape }}',
street_name_needs_correction: '{{ \"enderecoshopware6clientstore.statuses.street_name_needs_correction\"|trans|sw_sanitize|escape }}',
locality_needs_correction: '{{ \"enderecoshopware6clientstore.statuses.locality_needs_correction\"|trans|sw_sanitize|escape }}',
postal_code_needs_correction: '{{ \"enderecoshopware6clientstore.statuses.postal_code_needs_correction\"|trans|sw_sanitize|escape }}',
country_code_needs_correction: '{{ \"enderecoshopware6clientstore.statuses.country_code_needs_correction\"|trans|sw_sanitize|escape }}',
}
};
window.EnderecoIntegrator.activeServices = {
ams: true,
emailService: false,
personService: false
}
// Execute all function that have been called throughout the page.
window.EnderecoIntegrator.onLoad.forEach(function (callback) {
callback();
});
window.EnderecoIntegrator.ready = true;
(function() {
window.EnderecoIntegrator.\$formScanner = {
loop: null,
start: function() {
this.loop = setInterval( function() {
document.querySelectorAll('[name=\"endereco_data_marker\"][data-has-object=\"no\"]').forEach( function(MarkerElement) {
var formElement = MarkerElement.closest('form');
var formId = '';
if (formElement.getAttribute('data-endereco-ams-form-id')) {
formId = formElement.getAttribute('data-endereco-ams-form-id');
} else {
formId = (Math.floor(Math.random() * 100) * Date.now()).toString(16);
formElement.setAttribute('data-endereco-ams-form-id', formId);
}
if ('ams' === MarkerElement.value) {
var prefix = MarkerElement.getAttribute('data-used-prefix');
var countryCodeSelector = MarkerElement.getAttribute('data-country-code-selector');
var postalCodeSelector = MarkerElement.getAttribute('data-postal-code-selector');
var localitySelector = MarkerElement.getAttribute('data-locality-selector');
var streetFullSelector = MarkerElement.getAttribute('data-street-full-selector');
var subdivisionCodeSelector = MarkerElement.getAttribute('data-subdivision-code-selector');
var isAjax = false;
var EAO = window.EnderecoIntegrator.initAMS(
{
countryCode: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${countryCodeSelector}\"]`,
subdivisionCode: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${subdivisionCodeSelector}\"]`,
postalCode: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${postalCodeSelector}\"]`,
locality: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${localitySelector}\"]`,
streetFull: `[data-endereco-ams-form-id=\"\${formId}\"] [name=\"\${streetFullSelector}\"]`,
}, {
name: `ams_\${prefix}_\${formId}`,
addressType: 'general_address'
}
);
// If ajax, add click listener.
isAjax = 'true' === formElement.getAttribute('data-form-ajax-submit');
if (isAjax) {
formElement.querySelector('[type=\"submit\"]').addEventListener('click', function(e) {
if (EAO.util.shouldBeChecked()) {
e.preventDefault();
// Resume click after ac is done.
window.EnderecoIntegrator.submitResume = function() {
EAO.waitUntilReady().then( function() {
if(e.target.dispatchEvent(
new EAO.util.CustomEvent(
'click',
{
'bubbles': true,
'cancelable': true
}
)
)) {
e.target.click();
}
}).catch();
}
EAO.util.checkAddress().then().catch(function() {
EAO.waitUntilReady().then( function() {
if(e.target.dispatchEvent(
new EAO.util.CustomEvent(
'click',
{
'bubbles': true,
'cancelable': true
}
)
)) {
e.target.click();
}
}).catch();
});
return false;
}
});
}
}
MarkerElement.setAttribute('data-has-object', 'yes');
});
}, 1);
},
stop: function() {
}
}
window.EnderecoIntegrator.\$formScanner.start();
})();
}
function enderecoLoadAMSConfig() {
var \$interval = setInterval( function() {
if (!!window.EnderecoIntegrator.config) {
enderecoSetConfigValues();
clearInterval(\$interval);
}
}, 1);
}
</script>
{{ parent() }}
{% endblock %}
", "@EnderecoShopware6ClientStore/storefront/layout/meta.html.twig", "/srv/users/liamoriasw6/apps/liamoriasw6/custom/plugins/EnderecoShopware6ClientStore/src/Resources/views/storefront/layout/meta.html.twig");
}
}