feat(widgets): complete phase 3 atomic integration
This commit is contained in:
@@ -76,7 +76,6 @@ require_once AKSRT_DIR . '/inc/modules/captcha.php';
|
||||
require_once AKSRT_DIR . '/inc/modules/user-hub.php';
|
||||
require_once AKSRT_DIR . '/inc/modules/user-notifications.php';
|
||||
require_once AKSRT_DIR . '/inc/modules/creator-revenue.php';
|
||||
require_once AKSRT_DIR . '/inc/modules/widgets-register.php';
|
||||
|
||||
// Stage 3: core hooks
|
||||
require_once AKSRT_DIR . '/inc/core-hooks.php';
|
||||
|
||||
@@ -63,7 +63,7 @@ if (!function_exists('aksrt_single_render_aside')) :
|
||||
// from an otherwise two-column article page.
|
||||
|
||||
$has_article_widgets = is_active_sidebar('all_sidebar_top')
|
||||
|| is_active_sidebar('sidebar-article')
|
||||
|| is_active_sidebar('single_sidebar')
|
||||
|| is_active_sidebar('all_sidebar_bottom');
|
||||
?>
|
||||
<div class="aksrt-article-sidebar" role="complementary" aria-label="<?php esc_attr_e('侧栏', 'aksrt'); ?>">
|
||||
@@ -85,8 +85,8 @@ if (!function_exists('aksrt_single_render_aside')) :
|
||||
<?php if (is_active_sidebar('all_sidebar_top')) : ?>
|
||||
<?php dynamic_sidebar('all_sidebar_top'); ?>
|
||||
<?php endif; ?>
|
||||
<?php if (is_active_sidebar('sidebar-article')) : ?>
|
||||
<?php dynamic_sidebar('sidebar-article'); ?>
|
||||
<?php if (is_active_sidebar('single_sidebar')) : ?>
|
||||
<?php dynamic_sidebar('single_sidebar'); ?>
|
||||
<?php endif; ?>
|
||||
<?php if (is_active_sidebar('all_sidebar_bottom')) : ?>
|
||||
<?php dynamic_sidebar('all_sidebar_bottom'); ?>
|
||||
|
||||
@@ -104,7 +104,7 @@ if (!function_exists('aksrt_single_build_context')) :
|
||||
? aksrt_get_post_show_layout($post_id)
|
||||
: '';
|
||||
$has_article_widgets = is_active_sidebar('all_sidebar_top')
|
||||
|| is_active_sidebar('sidebar-article')
|
||||
|| is_active_sidebar('single_sidebar')
|
||||
|| is_active_sidebar('all_sidebar_bottom');
|
||||
// Do not use wp_is_mobile() as a layout gate. It is User-Agent based and
|
||||
// can disagree with the actual viewport (for example, desktop-mode mobile
|
||||
|
||||
@@ -23,7 +23,7 @@ if (!function_exists('aksrt_resolve_sidebar_id')):
|
||||
*/
|
||||
function aksrt_resolve_sidebar_id(): string {
|
||||
if (is_single()) {
|
||||
return 'sidebar-article';
|
||||
return 'single_sidebar';
|
||||
}
|
||||
|
||||
if (is_category()) {
|
||||
@@ -39,7 +39,7 @@ function aksrt_resolve_sidebar_id(): string {
|
||||
}
|
||||
|
||||
if (is_author()) {
|
||||
return 'author-sidebar';
|
||||
return '';
|
||||
}
|
||||
|
||||
if (is_page()) {
|
||||
|
||||
@@ -29,7 +29,7 @@ if (!function_exists('aksrt_homepage_render_layout')) {
|
||||
|
||||
// Fluid zones live outside <main>, once only (removed from header.php).
|
||||
aksrt_homepage_render_widget_zone(
|
||||
['all_top_fluid', 'home_top_fluid'],
|
||||
['home_top_fluid'],
|
||||
'fluid-widget-wrap aksrt-homepage__fluid-zone aksrt-homepage__fluid-zone--top'
|
||||
);
|
||||
?>
|
||||
@@ -142,7 +142,7 @@ if (!function_exists('aksrt_homepage_render_layout')) {
|
||||
</main>
|
||||
<?php
|
||||
aksrt_homepage_render_widget_zone(
|
||||
['home_bottom_fluid', 'all_bottom_fluid'],
|
||||
['home_bottom_fluid'],
|
||||
'fluid-widget-wrap aksrt-homepage__fluid-zone aksrt-homepage__fluid-zone--bottom'
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,148 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* Widget placement and area filtering.
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
|
||||
defined('ABSPATH') || exit;
|
||||
|
||||
function aksrt_widget_sidebar_area_ids(): array {
|
||||
return ['home_sidebar', 'sidebar-article', 'all_sidebar_top', 'all_sidebar_bottom', 'cat_sidebar', 'tag_sidebar', 'search_sidebar'];
|
||||
}
|
||||
|
||||
function aksrt_widget_archive_area_ids(): array {
|
||||
return ['cat_top_fluid', 'cat_top_content', 'cat_bottom_content', 'cat_bottom_fluid', 'cat_sidebar', 'tag_top_fluid', 'tag_top_content', 'tag_bottom_content', 'tag_bottom_fluid', 'tag_sidebar', 'search_top_fluid', 'search_top_content', 'search_bottom_content', 'search_bottom_fluid', 'search_sidebar'];
|
||||
}
|
||||
|
||||
function aksrt_widget_homepage_area_ids(): array {
|
||||
return ['home_top_fluid', 'home_top_content', 'home_bottom_content', 'home_bottom_fluid'];
|
||||
}
|
||||
|
||||
function aksrt_widget_single_area_ids(): array {
|
||||
return ['single_top_fluid', 'single_top_content', 'single_bottom_content', 'single_bottom_fluid'];
|
||||
}
|
||||
|
||||
function aksrt_widget_base_from_id(string $widget_id): string {
|
||||
return preg_replace('/-\d+$/', '', $widget_id) ?: $widget_id;
|
||||
}
|
||||
|
||||
function aksrt_widget_allowed_sidebars(string $widget_base_id): array {
|
||||
$sidebar_only = ['aksrt_categories', 'aksrt_tag_cloud', 'aksrt_hot_posts'];
|
||||
$homepage_only = ['aksrt_category_recommend'];
|
||||
$hybrid = ['aksrt_tab_posts', 'aksrt_category_block', 'aksrt_category_tabs'];
|
||||
|
||||
if (in_array($widget_base_id, $sidebar_only, true)) {
|
||||
return aksrt_widget_sidebar_area_ids();
|
||||
}
|
||||
if (in_array($widget_base_id, $homepage_only, true)) {
|
||||
return aksrt_widget_homepage_area_ids();
|
||||
}
|
||||
if (in_array($widget_base_id, $hybrid, true)) {
|
||||
return array_values(array_unique(array_merge(aksrt_widget_sidebar_area_ids(), aksrt_widget_homepage_area_ids())));
|
||||
}
|
||||
if ($widget_base_id === 'aksrt_post_pay_box') {
|
||||
return ['sidebar-article'];
|
||||
}
|
||||
return [];
|
||||
}
|
||||
|
||||
function aksrt_widget_is_allowed_in_sidebar(string $widget_base_id, string $sidebar_id): bool {
|
||||
if ($widget_base_id === '' || $sidebar_id === '') {
|
||||
return true;
|
||||
}
|
||||
if ($sidebar_id === 'wp_inactive_widgets' || strpos($sidebar_id, 'orphaned_widgets') === 0) {
|
||||
return true;
|
||||
}
|
||||
$allowed = aksrt_widget_allowed_sidebars($widget_base_id);
|
||||
return empty($allowed) || in_array($sidebar_id, $allowed, true);
|
||||
}
|
||||
|
||||
function aksrt_widget_get_area_context(array $args): string {
|
||||
$sidebar_id = isset($args['id']) ? (string) $args['id'] : '';
|
||||
if (in_array($sidebar_id, aksrt_widget_sidebar_area_ids(), true)) {
|
||||
return 'sidebar';
|
||||
}
|
||||
if (in_array($sidebar_id, aksrt_widget_homepage_area_ids(), true)) {
|
||||
return 'homepage';
|
||||
}
|
||||
if (in_array($sidebar_id, aksrt_widget_archive_area_ids(), true)) {
|
||||
return 'archive';
|
||||
}
|
||||
if (in_array($sidebar_id, aksrt_widget_single_area_ids(), true)) {
|
||||
return 'single';
|
||||
}
|
||||
return 'other';
|
||||
}
|
||||
|
||||
function aksrt_widget_render_location_help(string $scope): void {
|
||||
$messages = [
|
||||
'sidebar' => __('仅限侧栏区域:首页侧栏、文章页侧边栏、全站侧栏、分类/标签/搜索侧栏。', 'aksrt'),
|
||||
'homepage' => __('仅限首页挂载区域:首页顶部/底部全宽、首页内容上方/下方。', 'aksrt'),
|
||||
'hybrid' => __('支持侧栏、首页和归档页挂载区域。', 'aksrt'),
|
||||
'archive' => __('仅限归档页挂载区域:分类页、标签页、搜索页的顶部/底部/侧栏。', 'aksrt'),
|
||||
];
|
||||
if (empty($messages[$scope])) {
|
||||
return;
|
||||
}
|
||||
printf('<p style="margin-top:10px;font-size:12px;color:#666;">%s</p>', esc_html($messages[$scope]));
|
||||
}
|
||||
|
||||
function aksrt_filter_widget_display_by_area($instance, WP_Widget $widget, array $args) {
|
||||
if ($instance === false) {
|
||||
return false;
|
||||
}
|
||||
$sidebar_id = isset($args['id']) ? (string) $args['id'] : '';
|
||||
$widget_base_id = isset($widget->id_base) ? (string) $widget->id_base : '';
|
||||
return aksrt_widget_is_allowed_in_sidebar($widget_base_id, $sidebar_id) ? $instance : false;
|
||||
}
|
||||
add_filter('widget_display_callback', 'aksrt_filter_widget_display_by_area', 10, 3);
|
||||
|
||||
function aksrt_filter_widget_sidebar_assignments($new_value, $old_value) {
|
||||
if (!is_array($new_value)) {
|
||||
return $new_value;
|
||||
}
|
||||
$removed = [];
|
||||
foreach ($new_value as $sidebar_id => $widget_ids) {
|
||||
if (!is_array($widget_ids) || $sidebar_id === 'wp_inactive_widgets') {
|
||||
continue;
|
||||
}
|
||||
$filtered = [];
|
||||
foreach ($widget_ids as $widget_id) {
|
||||
if (!is_string($widget_id) || $widget_id === '') {
|
||||
continue;
|
||||
}
|
||||
$widget_base_id = aksrt_widget_base_from_id($widget_id);
|
||||
if (aksrt_widget_is_allowed_in_sidebar($widget_base_id, (string) $sidebar_id)) {
|
||||
$filtered[] = $widget_id;
|
||||
} else {
|
||||
$removed[] = $widget_id;
|
||||
}
|
||||
}
|
||||
$new_value[$sidebar_id] = array_values($filtered);
|
||||
}
|
||||
if (empty($removed)) {
|
||||
return $new_value;
|
||||
}
|
||||
if (!isset($new_value['wp_inactive_widgets']) || !is_array($new_value['wp_inactive_widgets'])) {
|
||||
$new_value['wp_inactive_widgets'] = [];
|
||||
}
|
||||
$assigned = [];
|
||||
foreach ($new_value as $widget_ids) {
|
||||
if (!is_array($widget_ids)) {
|
||||
continue;
|
||||
}
|
||||
foreach ($widget_ids as $widget_id) {
|
||||
if (is_string($widget_id) && $widget_id !== '') {
|
||||
$assigned[$widget_id] = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
foreach (array_values(array_unique($removed)) as $widget_id) {
|
||||
if (!isset($assigned[$widget_id]) && !in_array($widget_id, $new_value['wp_inactive_widgets'], true)) {
|
||||
$new_value['wp_inactive_widgets'][] = $widget_id;
|
||||
}
|
||||
}
|
||||
return $new_value;
|
||||
}
|
||||
add_filter('pre_update_option_sidebars_widgets', 'aksrt_filter_widget_sidebar_assignments', 10, 2);
|
||||
@@ -1,29 +0,0 @@
|
||||
<?php
|
||||
/** Shared forward widget contract. */
|
||||
defined('ABSPATH') || exit;
|
||||
|
||||
function aksrt_widget_common_defaults(): array {
|
||||
return class_exists('\\AKSRT\\Widgets\\CommonWidgetFields') ? \AKSRT\Widgets\CommonWidgetFields::defaults() : ['subtitle'=>'','title_link'=>'','display_pc'=>1,'display_mobile'=>1,'sticky'=>0,'animation'=>'none','background'=>'surface','dark_background'=>'surface'];
|
||||
}
|
||||
function aksrt_widget_common_normalize(array $instance): array {
|
||||
if (class_exists('\\AKSRT\\Widgets\\CommonWidgetFields')) return \AKSRT\Widgets\CommonWidgetFields::normalize($instance);
|
||||
$d = aksrt_widget_common_defaults();
|
||||
$out = $instance;
|
||||
$out['subtitle'] = sanitize_text_field((string)($instance['subtitle'] ?? $d['subtitle']));
|
||||
$out['title_link'] = esc_url_raw((string)($instance['title_link'] ?? ''));
|
||||
foreach (['display_pc','display_mobile','sticky'] as $key) $out[$key] = !empty($instance[$key]) ? 1 : 0;
|
||||
$out['animation'] = in_array(($a = sanitize_key((string)($instance['animation'] ?? 'none'))), ['none','fade','slide'], true) ? $a : 'none';
|
||||
$out['background'] = in_array(($b = sanitize_key((string)($instance['background'] ?? 'surface'))), ['surface','transparent','primary'], true) ? $b : 'surface';
|
||||
$out['dark_background'] = in_array(($db = sanitize_key((string)($instance['dark_background'] ?? 'surface'))), ['surface','transparent','primary'], true) ? $db : 'surface';
|
||||
return $out;
|
||||
}
|
||||
function aksrt_widget_common_form(WP_Widget $widget, array $instance): void {
|
||||
$v = aksrt_widget_common_normalize($instance);
|
||||
$field = static function(string $key) use ($widget): string { return esc_attr($widget->get_field_name($key)); };
|
||||
echo '<p><label for="' . esc_attr($widget->get_field_id('subtitle')) . '">' . esc_html__('副标题', 'aksrt') . '</label><input class="widefat" id="' . esc_attr($widget->get_field_id('subtitle')) . '" name="' . $field('subtitle') . '" type="text" value="' . esc_attr($v['subtitle']) . '"></p>';
|
||||
echo '<p><label for="' . esc_attr($widget->get_field_id('title_link')) . '">' . esc_html__('标题链接', 'aksrt') . '</label><input class="widefat" id="' . esc_attr($widget->get_field_id('title_link')) . '" name="' . $field('title_link') . '" type="url" value="' . esc_attr($v['title_link']) . '"></p>';
|
||||
echo '<p><label><input type="checkbox" name="' . $field('display_pc') . '" value="1" ' . checked($v['display_pc'], 1, false) . '> ' . esc_html__('桌面端显示', 'aksrt') . '</label> <label><input type="checkbox" name="' . $field('display_mobile') . '" value="1" ' . checked($v['display_mobile'], 1, false) . '> ' . esc_html__('移动端显示', 'aksrt') . '</label> <label><input type="checkbox" name="' . $field('sticky') . '" value="1" ' . checked($v['sticky'], 1, false) . '> ' . esc_html__('侧栏吸顶', 'aksrt') . '</label></p>';
|
||||
echo '<p><label>' . esc_html__('入场动画', 'aksrt') . '<select class="widefat" name="' . $field('animation') . '"><option value="none" ' . selected($v['animation'], 'none', false) . '>None</option><option value="fade" ' . selected($v['animation'], 'fade', false) . '>Fade</option><option value="slide" ' . selected($v['animation'], 'slide', false) . '>Slide</option></select></label></p>';
|
||||
}
|
||||
add_filter('widget_update_callback', static function($instance, $new_instance, $old_instance, $widget) { return is_array($instance) ? aksrt_widget_common_normalize($instance) : $instance; }, 10, 4);
|
||||
add_action('in_widget_form', static function(WP_Widget $widget, &$return, array $instance): void { aksrt_widget_common_form($widget, $instance); }, 20, 3);
|
||||
@@ -1,144 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* Widget registration and placement rules.
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
|
||||
defined('ABSPATH') || exit;
|
||||
|
||||
require_once AKSRT_DIR . '/inc/modules/widget-areas.php';
|
||||
require_once AKSRT_DIR . '/inc/modules/widget-common.php';
|
||||
|
||||
/**
|
||||
* Register custom widgets.
|
||||
*/
|
||||
function aksrt_unregister_default_widgets(): void {
|
||||
unregister_widget('WP_Widget_RSS');
|
||||
unregister_widget('WP_Widget_Recent_Posts');
|
||||
unregister_widget('WP_Widget_Recent_Comments');
|
||||
unregister_widget('WP_Widget_Pages');
|
||||
unregister_widget('WP_Widget_Search');
|
||||
unregister_widget('WP_Widget_Calendar');
|
||||
unregister_widget('WP_Nav_Menu_Widget');
|
||||
}
|
||||
add_action('widgets_init', 'aksrt_unregister_default_widgets', 1);
|
||||
|
||||
function aksrt_register_widgets() {
|
||||
register_widget('\AKSRT\Widgets\CategoriesWidget');
|
||||
register_widget('\AKSRT\Widgets\TagCloudWidget');
|
||||
register_widget('\AKSRT\Widgets\HotPostsWidget');
|
||||
register_widget('\AKSRT\Widgets\TabPostsWidget');
|
||||
register_widget('\AKSRT\Widgets\CategoryBlockWidget');
|
||||
register_widget('\AKSRT\Widgets\CategoryTabsWidget');
|
||||
register_widget('\AKSRT\Widgets\CategoryRecommendWidget');
|
||||
|
||||
// 第一批通用 widget
|
||||
register_widget('\AKSRT\Widgets\SearchWidget');
|
||||
register_widget('\AKSRT\Widgets\NoticeWidget');
|
||||
register_widget('\AKSRT\Widgets\RecentCommentsWidget');
|
||||
register_widget('\AKSRT\Widgets\IconCardsWidget');
|
||||
register_widget('\AKSRT\Widgets\ButtonsWidget');
|
||||
|
||||
// 公告跑马灯
|
||||
register_widget('\AKSRT\Widgets\WidgetAnnouncement');
|
||||
|
||||
// 用户卡片
|
||||
register_widget('\AKSRT\Widgets\WidgetUserCard');
|
||||
|
||||
// 图文封面卡片
|
||||
register_widget('\AKSRT\Widgets\WidgetCoverCards');
|
||||
|
||||
// 视频播放器
|
||||
register_widget('\AKSRT\Widgets\WidgetVideoPlayer');
|
||||
|
||||
// 一言轮播
|
||||
register_widget('\AKSRT\Widgets\WidgetYiyan');
|
||||
|
||||
// 幻灯片
|
||||
register_widget('\AKSRT\Widgets\WidgetSlider');
|
||||
|
||||
// 其余通用小工具
|
||||
register_widget('\AKSRT\Widgets\WidgetIframe');
|
||||
register_widget('\AKSRT\Widgets\WidgetComboInfo');
|
||||
register_widget('\AKSRT\Widgets\WidgetTextTitle');
|
||||
register_widget('\AKSRT\Widgets\WidgetTermCards');
|
||||
register_widget('\AKSRT\Widgets\WidgetPostPayBox');
|
||||
register_widget('\AKSRT\Widgets\WidgetAuthorCard');
|
||||
register_widget('\AKSRT\Widgets\WidgetOnelinePosts');
|
||||
register_widget('\AKSRT\Widgets\WidgetMainPosts');
|
||||
register_widget('\AKSRT\Widgets\WidgetTermAggregation');
|
||||
register_widget('\AKSRT\Widgets\WidgetIconCoverCards');
|
||||
register_widget('\AKSRT\Widgets\PricingPlansWidget');
|
||||
register_widget('\AKSRT\Widgets\TestimonialsWidget');
|
||||
register_widget('\AKSRT\Widgets\FaqWidget');
|
||||
register_widget('\AKSRT\Widgets\StatsWidget');
|
||||
register_widget('\AKSRT\Widgets\HighlightsWidget');
|
||||
register_widget('\AKSRT\Widgets\PartnersWidget');
|
||||
}
|
||||
add_action('widgets_init', 'aksrt_register_widgets');
|
||||
|
||||
/**
|
||||
* Register a block editor collection for AKSRT widgets.
|
||||
*/
|
||||
add_action('enqueue_block_editor_assets', function () {
|
||||
$screen = get_current_screen();
|
||||
if (!$screen || $screen->id !== 'widgets') {
|
||||
return;
|
||||
}
|
||||
|
||||
wp_add_inline_script('wp-blocks', '
|
||||
document.addEventListener("DOMContentLoaded", function() {
|
||||
if (typeof wp !== "undefined" && wp.blocks && wp.blocks.registerBlockCollection) {
|
||||
wp.blocks.registerBlockCollection("aksrt", {
|
||||
title: "AKSRT 主题小工具",
|
||||
icon: undefined
|
||||
});
|
||||
}
|
||||
});
|
||||
');
|
||||
});
|
||||
|
||||
/**
|
||||
* Assign AKSRT widgets to the AKSRT block category in the widgets editor.
|
||||
*
|
||||
* @param array<string, mixed> $metadata Block metadata.
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
add_filter('block_type_metadata', function ($metadata) {
|
||||
$aksrt_widgets = [
|
||||
'aksrt_categories',
|
||||
'aksrt_tag_cloud',
|
||||
'aksrt_hot_posts','aksrt_tab_posts','aksrt_category_block','aksrt_category_tabs','aksrt_category_recommend',
|
||||
'aksrt_search','aksrt_notice','aksrt_recent_comments','aksrt_icon_cards','aksrt_buttons','aksrt_announcement','aksrt_user_card','aksrt_cover_cards','aksrt_video_player','aksrt_yiyan','aksrt_slider','aksrt_iframe','aksrt_combo_info','aksrt_text_title','aksrt_term_cards','aksrt_post_pay_box','aksrt_author_card','aksrt_oneline_posts','aksrt_main_posts','aksrt_term_aggregation','aksrt_icon_cover_cards',
|
||||
'aksrt_pricing_plans','aksrt_testimonials','aksrt_faq','aksrt_stats','aksrt_highlights','aksrt_partners',
|
||||
];
|
||||
|
||||
if (!empty($metadata['name']) && in_array($metadata['name'], $aksrt_widgets, true)) {
|
||||
$metadata['category'] = 'aksrt';
|
||||
}
|
||||
|
||||
return $metadata;
|
||||
});
|
||||
|
||||
/**
|
||||
* Show widget placement hints in the admin form.
|
||||
*/
|
||||
add_action('in_widget_form', function (WP_Widget $widget): void {
|
||||
$map = [
|
||||
'aksrt_categories' => 'sidebar',
|
||||
'aksrt_tag_cloud' => 'sidebar',
|
||||
'aksrt_hot_posts' => 'sidebar',
|
||||
'aksrt_tab_posts' => 'hybrid',
|
||||
'aksrt_category_block' => 'hybrid',
|
||||
'aksrt_category_tabs' => 'hybrid',
|
||||
'aksrt_category_recommend' => 'homepage',
|
||||
'aksrt_search'=>'sidebar','aksrt_notice'=>'sidebar','aksrt_recent_comments'=>'sidebar','aksrt_icon_cards'=>'hybrid','aksrt_buttons'=>'hybrid','aksrt_announcement'=>'homepage','aksrt_user_card'=>'sidebar','aksrt_cover_cards'=>'homepage','aksrt_video_player'=>'content','aksrt_yiyan'=>'sidebar','aksrt_slider'=>'homepage','aksrt_iframe'=>'content','aksrt_combo_info'=>'homepage','aksrt_text_title'=>'hybrid','aksrt_term_cards'=>'homepage','aksrt_post_pay_box'=>'content','aksrt_author_card'=>'content','aksrt_oneline_posts'=>'sidebar','aksrt_main_posts'=>'homepage','aksrt_term_aggregation'=>'homepage','aksrt_icon_cover_cards'=>'homepage',
|
||||
'aksrt_pricing_plans'=>'homepage','aksrt_testimonials'=>'homepage','aksrt_faq'=>'content','aksrt_stats'=>'homepage','aksrt_highlights'=>'homepage','aksrt_partners'=>'homepage',
|
||||
];
|
||||
|
||||
$scope = $map[$widget->id_base] ?? '';
|
||||
if ($scope !== '') {
|
||||
aksrt_widget_render_location_help($scope);
|
||||
}
|
||||
}, 10, 1);
|
||||
Reference in New Issue
Block a user