Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
unidocs-zh
提交
65d22726
unidocs-zh
项目概览
DCloud
/
unidocs-zh
通知
3598
Star
108
Fork
921
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
120
列表
看板
标记
里程碑
合并请求
109
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
unidocs-zh
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
120
Issue
120
列表
看板
标记
里程碑
合并请求
109
合并请求
109
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
65d22726
编写于
11月 04, 2022
作者:
D
DCloud_LXH
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
chore: darkmode.md
上级
b8a18991
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
8 addition
and
17 deletion
+8
-17
docs/tutorial/darkmode.md
docs/tutorial/darkmode.md
+8
-17
未找到文件。
docs/tutorial/darkmode.md
浏览文件 @
65d22726
...
...
@@ -16,21 +16,12 @@
2.
配置
`themeLocation`
,指定变量配置文件
`theme.json`
路径,例如:在根目录下新增
`theme.json`
,需要配置
`"themeLocation":"theme.json"`
3.
在
`theme.json`
中定义相关变量
4.
在
`pages.json`
中以@开头引用变量
5.
整体配置
5.
需要云端打包生效
6.
整体配置
```
json
"app-plus"
:
{
"darkmode"
:
false
,
"themeLocation"
:
"theme.json"
,
//
开启
darkmode。如果
theme.json
在根目录可省略
"distribute"
:
{
//
安卓端开启跟随系统主题。需要云端打包生效
"android"
:
{
"defaultNightMode"
:
"auto"
},
//
安卓端开启跟随系统主题。需要云端打包生效
"ios"
:
{
"UIUserInterfaceStyle"
:
"Automatic"
},
}
"darkmode"
:
true
,
"themeLocation"
:
"theme.json"
//
如果
theme.json
在根目录可省略
}
```
...
...
@@ -45,8 +36,8 @@
5
.
整体配置
```
json
"h5" : {
"darkmode" :
fals
e,
"themeLocation" : "theme.json" //
开启 darkmode。
如果 theme.json 在根目录可省略
"darkmode" :
tru
e,
"themeLocation" : "theme.json" // 如果 theme.json 在根目录可省略
}
```
...
...
@@ -61,8 +52,8 @@
5. 整体配置
```json
"mp-weixin" : {
"darkmode" :
fals
e,
"themeLocation" : "theme.json" //
开启 darkmode。
如果 theme.json 在根目录可省略
"darkmode" :
tru
e,
"themeLocation" : "theme.json" // 如果 theme.json 在根目录可省略
}
```
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录