(self["webpackChunk"] = self["webpackChunk"] || []).push([["app-frontend"],{

/***/ "./assets/app/frontend/app/app.common.js":
/*!***********************************************!*\
  !*** ./assets/app/frontend/app/app.common.js ***!
  \***********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _app_scss__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./app.scss */ "./assets/app/frontend/app/app.scss");
/* harmony import */ var _app_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./app.js */ "./assets/app/frontend/app/app.js");
/*
 * Welcome to your app's main JavaScript file!
 *
 * We recommend including the built version of this JavaScript file
 * (and its CSS file) in your base layout (base.html.twig).
 */
// any CSS you import will output into a single css file (app.css in this case)

 // start the Stimulus application
//import './bootstrap';

/***/ }),

/***/ "./assets/app/frontend/app/app.js":
/*!****************************************!*\
  !*** ./assets/app/frontend/app/app.js ***!
  \****************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var bootstrap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! bootstrap */ "./node_modules/bootstrap/dist/js/bootstrap.js");
/* harmony import */ var bootstrap__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(bootstrap__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _js_script__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../js/script */ "./assets/app/frontend/js/script.js");
/* harmony import */ var _js_script__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_js_script__WEBPACK_IMPORTED_MODULE_1__);



/***/ }),

/***/ "./assets/app/frontend/js/script.js":
/*!******************************************!*\
  !*** ./assets/app/frontend/js/script.js ***!
  \******************************************/
/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => {

__webpack_require__(/*! core-js/modules/es.regexp.exec.js */ "./node_modules/core-js/modules/es.regexp.exec.js");

__webpack_require__(/*! core-js/modules/es.string.split.js */ "./node_modules/core-js/modules/es.string.split.js");

$(document).ready(function () {
  menuToggle();
  manageFormContact();
  manageFormSearch();
});

function menuToggle() {
  var box = $('.menu-content');
  var button = $('.toggle');
  button.on('click', function () {
    box.toggle('slow');
  });
}

function manageFormSearch() {
  $(".dropdown-search").on("change", "input[type='checkbox']", function () {
    $(this).closest("li").toggleClass("active", this.checked);
  });
  $(document).on('click', '.allow-focus', function (e) {
    e.stopPropagation();
  });
  $('.pagination a').click(function (e) {
    console.log(this.href.split('page=')[1]);
    $('.hidden-page').val(this.href.split('page=')[1]);
    $('.search-button').click();
    return false;
  });
}

function manageFormContact() {
  $('#contact_lccap').val('blop');
  $('#contact-form-btn').on('click', function () {
    if (checkFormValidity('#contact-form')) {
      $('#contact-form').fadeOut(200);
      $form = $('#contact-form');
      $.ajax({
        url: $form.prop('action'),
        method: $form.prop('method'),
        data: $form.serialize(),
        dataType: "json",
        success: function success(response) {
          $('#contact-form').html('<p class="success-post">Merci pour votre message, nous vous r&eacute;pondrons dans les plus brefs d&eacute;lais.</p>');
          $('#contact-form').fadeIn(500);
        }
      });
    }
  });
}

function checkFormValidity(formId) {
  if (!document.getElementById(formId.substr(1)).checkValidity()) {
    document.getElementById(formId.substr(1)).reportValidity();
    return false;
  } else {
    return true;
  }
}

/***/ }),

/***/ "./assets/app/frontend/app/app.scss":
/*!******************************************!*\
  !*** ./assets/app/frontend/app/app.scss ***!
  \******************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
// extracted by mini-css-extract-plugin


/***/ })

},
/******/ __webpack_require__ => { // webpackRuntimeModules
/******/ "use strict";
/******/ 
/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
/******/ __webpack_require__.O(0, ["vendors-node_modules_core-js_internals_export_js","vendors-node_modules_core-js_internals_advance-string-index_js-node_modules_core-js_internals-bed4a0","vendors-node_modules_core-js_internals_a-function_js-node_modules_jquery_src_jquery_js","vendors-node_modules_core-js_modules_es_string_split_js-node_modules_popper_js_dist_esm_popper_js","vendors-node_modules_bootstrap_dist_js_bootstrap_js"], () => (__webpack_exec__("./assets/app/frontend/app/app.common.js")));
/******/ var __webpack_exports__ = __webpack_require__.O();
/******/ }
]);
//# sourceMappingURL=data:application/json;charset=utf-8;base64,[encoded data, 6664 characters]