30 lines
1.1 KiB
PHP
30 lines
1.1 KiB
PHP
<?php
|
|
declare(strict_types=1);
|
|
defined('ABSPATH') || exit;
|
|
|
|
add_action('after_setup_theme', 'xshop_setup_theme_support');
|
|
|
|
function xshop_setup_theme_support(): void {
|
|
add_theme_support('title-tag');
|
|
add_theme_support('post-thumbnails');
|
|
add_theme_support('html5', ['search-form','comment-form','comment-list','gallery','caption','style','script']);
|
|
add_theme_support('custom-logo', ['height'=>56,'width'=>200,'flex-height'=>true,'flex-width'=>true]);
|
|
add_theme_support('automatic-feed-links');
|
|
add_theme_support('responsive-embeds');
|
|
add_theme_support('editor-styles');
|
|
add_theme_support('wp-block-styles');
|
|
add_theme_support('woocommerce', [
|
|
'thumbnail_image_width' => 400,
|
|
'single_image_width' => 800,
|
|
]);
|
|
add_theme_support('wc-product-gallery-zoom');
|
|
add_theme_support('wc-product-gallery-lightbox');
|
|
add_theme_support('wc-product-gallery-slider');
|
|
|
|
load_theme_textdomain('xshop', XSHOP_THEME_DIR . '/languages');
|
|
|
|
// Image sizes.
|
|
add_image_size('xshop-card', 400, 400, false);
|
|
add_image_size('xshop-card-2x', 800, 800, false);
|
|
}
|