clean + moving acf blocks to plugin
This commit is contained in:
parent
6f2cfe31fb
commit
60f477e147
|
|
@ -59,16 +59,11 @@ function homegrade_enqueue_scripts()
|
||||||
$theme = wp_get_theme();
|
$theme = wp_get_theme();
|
||||||
|
|
||||||
wp_enqueue_script('gsap', get_template_directory_uri() . '/assets/gsap/gsap.min.js', array(), $theme->get('Version'));
|
wp_enqueue_script('gsap', get_template_directory_uri() . '/assets/gsap/gsap.min.js', array(), $theme->get('Version'));
|
||||||
// wp_enqueue_script('swiperjs', get_template_directory_uri() . '/assets/swiper/swiper-bundle.min.js', array(), $theme->get('Version'));
|
wp_enqueue_script('swiperjs', get_template_directory_uri() . '/assets/swiper/swiper-bundle_11.min.js', array(), $theme->get('Version'));
|
||||||
wp_enqueue_script('swiperjssss', get_template_directory_uri() . '/assets/swiper/swiper-bundle_11.min.js', array(), $theme->get('Version'));
|
|
||||||
wp_enqueue_style('swipercss', get_template_directory_uri() . '/assets/swiper/swiper-bundle.min.css', array(), $theme->get('Version'));
|
wp_enqueue_style('swipercss', get_template_directory_uri() . '/assets/swiper/swiper-bundle.min.css', array(), $theme->get('Version'));
|
||||||
wp_enqueue_style('tailpress', tailpress_asset('css/app.css'), array(), $theme->get('Version'));
|
wp_enqueue_style('tailpress', tailpress_asset('css/app.css'), array(), $theme->get('Version'));
|
||||||
|
|
||||||
// wp_enqueue_script('tailpress', tailpress_asset('js/app.js'), array('gsap', 'jquery'), $theme->get('Version'));
|
|
||||||
// wp_register_script('showthematiquejs', get_template_directory_uri() . '/template-blocks/home/show-thematiques/show-thematiques.js', array('swiperjs', 'swipercss'), $theme->get('Version'));
|
|
||||||
|
|
||||||
// #PASSING TRANSLATIONS
|
// #PASSING TRANSLATIONS
|
||||||
// wp_register_script('main-app-js', tailpress_asset('js/app.js'), array('gsap', 'jquery'), $theme->get('Version'));
|
|
||||||
wp_register_script('main-app-js', get_template_directory_uri() . '/js/app.js', array('gsap', 'jquery'), $theme->get('Version'));
|
wp_register_script('main-app-js', get_template_directory_uri() . '/js/app.js', array('gsap', 'jquery'), $theme->get('Version'));
|
||||||
|
|
||||||
$main_app_js_dynamic_datas = array(
|
$main_app_js_dynamic_datas = array(
|
||||||
|
|
@ -80,26 +75,6 @@ function homegrade_enqueue_scripts()
|
||||||
wp_localize_script('main-app-js', 'mainAppJsDynamicDatas', $main_app_js_dynamic_datas);
|
wp_localize_script('main-app-js', 'mainAppJsDynamicDatas', $main_app_js_dynamic_datas);
|
||||||
|
|
||||||
wp_enqueue_script('main-app-js');
|
wp_enqueue_script('main-app-js');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// SHOW THEMATIQUE
|
|
||||||
// wp_register_script('showthematiquejs', get_template_directory_uri() . '/template-blocks/home/show-thematiques/show-thematiques.js');
|
|
||||||
wp_register_script('showthematiquejs', get_template_directory_uri() . '/template-blocks/home/show-thematiques/show-thematiques.js', array('main-app-js', 'swiperjssss'));
|
|
||||||
|
|
||||||
$translation_array = array(
|
|
||||||
'previousSlide' => __('Carte précédente', 'homegrade-theme__texte-fonctionnel'),
|
|
||||||
'nextSlide' => __('Carte suivante', 'homegrade-theme__texte-fonctionnel'),
|
|
||||||
'slideLabel' => __('Carte Thématique', 'homegrade-theme__texte-fonctionnel'),
|
|
||||||
);
|
|
||||||
wp_localize_script('showthematiquejs', 'textTranslations', $translation_array);
|
|
||||||
|
|
||||||
wp_enqueue_script('showthematiquejs');
|
|
||||||
|
|
||||||
// wp_enqueue_script('swiperjs', get_template_directory_uri() . '/assets/swiper/swiper-bundle.min.js', array('tailpress'), $theme->get('Version'), true);
|
|
||||||
// wp_register_style('swipercss', get_template_directory_uri() . '/assets/swiper/swiper-bundle.min.css', array(), $theme->get('Version'));
|
|
||||||
}
|
}
|
||||||
add_action('wp_enqueue_scripts', 'homegrade_enqueue_scripts');
|
add_action('wp_enqueue_scripts', 'homegrade_enqueue_scripts');
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user