| @@ -5,8 +5,12 @@ | ||
| 5 | 5 | * |
| 6 | 6 | * @package automattic/jetpack |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | +if ( ! defined( 'ABSPATH' ) ) { | |
| 10 | + exit( 0 ); | |
| 11 | +} | |
| 12 | + | |
| 9 | 13 | /** |
| 10 | 14 | * Add Jetpack extra functionality to Twenty Twenty One. |
| 11 | 15 | */ |
| 12 | 16 | function twentytwentyone_jetpack_setup() { |
| @@ -22,33 +26,8 @@ | ||
| 22 | 26 | 'render' => 'twentytwentyone_infinite_scroll_render', |
| 23 | 27 | 'footer' => 'main', |
| 24 | 28 | ) |
| 25 | 29 | ); |
| 26 | - | |
| 27 | - /** | |
| 28 | - * Add theme support for geo-location. | |
| 29 | - */ | |
| 30 | - add_theme_support( 'jetpack-geo-location' ); | |
| 31 | - | |
| 32 | - /** | |
| 33 | - * Add theme support for Content Options. | |
| 34 | - */ | |
| 35 | - add_theme_support( | |
| 36 | - 'jetpack-content-options', | |
| 37 | - array( | |
| 38 | - 'blog-display' => array( 'content', 'excerpt' ), | |
| 39 | - 'post-details' => array( | |
| 40 | - 'stylesheet' => 'twenty-twenty-one-style', | |
| 41 | - 'date' => '.posted-on', | |
| 42 | - 'categories' => '.cat-links', | |
| 43 | - ), | |
| 44 | - 'featured-images' => array( | |
| 45 | - 'archive' => true, | |
| 46 | - 'post' => true, | |
| 47 | - 'page' => true, | |
| 48 | - ), | |
| 49 | - ) | |
| 50 | - ); | |
| 51 | 30 | } |
| 52 | 31 | add_action( 'after_setup_theme', 'twentytwentyone_jetpack_setup' ); |
| 53 | 32 | |
| 54 | 33 | /** |
| @@ -67,10 +46,10 @@ | ||
| 67 | 46 | * or skip it entirely for wpcom. |
| 68 | 47 | */ |
| 69 | 48 | function twentytwentyone_enqueue_jetpack_style() { |
| 70 | 49 | $version = Jetpack::is_development_version() |
| 71 | - ? filemtime( JETPACK__PLUGIN_DIR . 'modules/theme-tools/compat/twentytwentyone.css' ) | |
| 72 | - : JETPACK__VERSION; | |
| 50 | + ? filemtime( JETPACK__PLUGIN_DIR . 'modules/theme-tools/compat/twentytwentyone.css' ) | |
| 51 | + : JETPACK__VERSION; | |
| 73 | 52 | |
| 74 | 53 | wp_enqueue_style( 'twentytwentyone-jetpack', plugins_url( 'twentytwentyone.css', __FILE__ ), array(), $version ); |
| 75 | 54 | wp_style_add_data( 'twentytwentyone-jetpack', 'rtl', 'replace' ); |
| 76 | 55 | } |