File: //proc/self/cwd/wp-content/themes/xts-luman/templates/elementor/single-product/countdown.php
<?php
/**
* Product countdown function
*
* @package xts
*/
use XTS\Framework\Modules;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Direct access not allowed.
}
if ( ! function_exists( 'xts_single_product_countdown_template' ) ) {
/**
* Product countdown template
*
* @since 1.0.0
*
* @param array $element_args Associative array of arguments.
*/
function xts_single_product_countdown_template( $element_args ) {
if ( ! xts_is_woocommerce_installed() ) {
return;
}
$default_args = array(
'text_align' => 'left',
);
$element_args = wp_parse_args( $element_args, $default_args );
$countdown_module = Modules::get( 'wc-product-countdown' );
$classes = 'xts-with-shadow';
if ( ! empty( $element_args['text_align'] ) ) {
$classes .= ' xts-textalign-' . $element_args['text_align'];
}
$countdown_module->product_countdown( $classes );
}
}