导入 AKSRT 主题开发源码
This commit is contained in:
1 parent
9681dd3d48
commit
1268a55dd0
595 files changed
+127705
No files matched your search
@@ -0,0 +1,53 @@
|
||||
<?php
|
||||
/**
|
||||
* AKSRT_Admin_Schema_Extensions_Docs_Mode section schema.
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
|
||||
defined('ABSPATH') || exit;
|
||||
|
||||
class AKSRT_Admin_Schema_Extensions_Docs_Mode {
|
||||
|
||||
public static function build(): array {
|
||||
return [
|
||||
'key' => 'docs-mode',
|
||||
'title' => '文档模式',
|
||||
'version' => '1.0.0',
|
||||
'option_key' => 'aksrt_settings',
|
||||
'groups' => [
|
||||
['key' => 'basic', 'title' => '基础配置', 'fields' => [
|
||||
['key' => 'docs_mode_enabled', 'label' => '启用文档模式', 'type' => 'switch', 'default' => false],
|
||||
['key' => 'docs_mode_default_template', 'label' => '文档首页模板', 'type' => 'select', 'default' => 'documentnav', 'options' => [
|
||||
['label' => '文档导航页', 'value' => 'documentnav'],
|
||||
['label' => '专题聚合页', 'value' => 'special'],
|
||||
]],
|
||||
]],
|
||||
['key' => 'navigation', 'title' => '导航设置', 'fields' => [
|
||||
['key' => 'docs_mode_toc_enabled', 'label' => '显示目录树', 'type' => 'switch', 'default' => true],
|
||||
['key' => 'docs_mode_chapter_nav_enabled', 'label' => '显示章节导航', 'type' => 'switch', 'default' => true],
|
||||
['key' => 'docs_mode_default_order', 'label' => '默认排序', 'type' => 'radio', 'default' => 'menu_order', 'options' => [
|
||||
['label' => '按菜单顺序', 'value' => 'menu_order'],
|
||||
['label' => '按发布时间', 'value' => 'date'],
|
||||
['label' => '按标题排序', 'value' => 'title'],
|
||||
]],
|
||||
['key' => 'docs_mode_toc_depth', 'label' => '目录深度', 'type' => 'number', 'default' => 3, 'min' => 1, 'max' => 6],
|
||||
['key' => 'docs_mode_chapter_title', 'label' => '章节标题', 'type' => 'input', 'default' => ''],
|
||||
]],
|
||||
['key' => 'filter', 'title' => '筛选设置', 'fields' => [
|
||||
['key' => 'docs_mode_cats', 'label' => '文档分类', 'type' => 'taxonomy_select', 'taxonomy' => 'category', 'multiple' => true, 'default' => []],
|
||||
['key' => 'docs_mode_exclude', 'label' => '在首页排除此类内容', 'type' => 'switch', 'default' => true],
|
||||
]],
|
||||
['key' => 'style', 'title' => '样式设置', 'fields' => [
|
||||
['key' => 'docs_mode_style', 'label' => '文档样式', 'type' => 'select', 'default' => 'default', 'options' => [
|
||||
['label' => '默认', 'value' => 'default'],
|
||||
['label' => '简洁', 'value' => 'simple'],
|
||||
['label' => '卡片', 'value' => 'card'],
|
||||
]],
|
||||
['key' => 'docs_mode_icon', 'label' => '显示图标', 'type' => 'switch', 'default' => true],
|
||||
['key' => 'docs_mode_count', 'label' => '显示文章数', 'type' => 'switch', 'default' => true],
|
||||
]],
|
||||
],
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user