fix(list): wire Zibll list/card display chain end-to-end
Resolve post list mode from global list_type + surface card overrides so homepage/archives/AJAX honor admin list and card style settings.
This commit is contained in:
1 parent
b2815614d1
commit
d73a7af25e
17 files changed
+444
-151
No files matched your search
@@ -25,14 +25,13 @@ get_header();
|
||||
<div class="content-layout<?php echo $has_sidebar ? '' : ' content-layout--no-sidebar'; ?>">
|
||||
<div class="content-layout__primary">
|
||||
<?php
|
||||
$post_layout = class_exists('AKSRT_Settings')
|
||||
? AKSRT_Settings::get_archive_layout()
|
||||
: 'grid-cms';
|
||||
$render_mode = in_array($post_layout, ['list', 'mini'], true) ? $post_layout : 'card';
|
||||
$render_config = function_exists('aksrt_resolve_post_list_render_config')
|
||||
? aksrt_resolve_post_list_render_config(['context' => 'archive'])
|
||||
: ['context' => 'archive', 'mode' => 'list'];
|
||||
?>
|
||||
|
||||
<?php if (have_posts()) : ?>
|
||||
<?php aksrt_render_post_list(null, ['context' => 'archive', 'mode' => $render_mode, 'card_style' => 'standard']); ?>
|
||||
<?php aksrt_render_post_list(null, $render_config); ?>
|
||||
<?php aksrt_render_pagination(); ?>
|
||||
<?php else : ?>
|
||||
<div class="no-results">
|
||||
|
||||
Reference in new issue
Block a user