feat(share): align social sharing runtime
This commit is contained in:
@@ -551,34 +551,6 @@ trait ScriptsPart1b {
|
||||
}
|
||||
}
|
||||
|
||||
// Unified share-data builder — only when the article renders share controls.
|
||||
if (!empty($singular_assets['needs_share'])) {
|
||||
$share_data_js = get_template_directory() . '/assets/js/share-data-builder.js';
|
||||
if (file_exists($share_data_js)) {
|
||||
wp_enqueue_script(
|
||||
'aksrt-share-data',
|
||||
$base_uri . '/assets/js/share-data-builder.js',
|
||||
['loader_js'],
|
||||
(string) filemtime($share_data_js),
|
||||
true
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// Poster generation is part of the article share dropdown.
|
||||
if (!empty($singular_assets['needs_share'])) {
|
||||
$poster_js = get_template_directory() . '/assets/js/poster-share.js';
|
||||
if (file_exists($poster_js)) {
|
||||
wp_enqueue_script(
|
||||
'aksrt-poster-share',
|
||||
$base_uri . '/assets/js/poster-share.js',
|
||||
['loader_js', 'aksrt-share-data'],
|
||||
(string) filemtime($poster_js),
|
||||
true
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// Unified authentication page shell.
|
||||
if ($is_auth_page) {
|
||||
$enqueue_module('pages');
|
||||
|
||||
Reference in New Issue
Block a user