Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
pro-layout
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
packages
pro-layout
Commits
628c9f12
Commit
628c9f12
authored
May 14, 2020
by
Sendya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: theme key
parent
7954c750
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
6 deletions
+6
-6
README.md
README.md
+1
-1
README.zh-CN.md
README.zh-CN.md
+1
-1
index.jsx
src/components/SettingDrawer/index.jsx
+4
-4
No files found.
README.md
View file @
628c9f12
...
@@ -138,7 +138,7 @@ export default {
...
@@ -138,7 +138,7 @@ export default {
| Property | Description | Type | Default Value |
| Property | Description | Type | Default Value |
| ---- | ---- | ---- | ---- |
| ---- | ---- | ---- | ---- |
|
navT
heme | Theme |
`dark`
`light`
`realDark`
|
`light`
|
|
t
heme | Theme |
`dark`
`light`
`realDark`
|
`light`
|
| layout | Sider Layout |
`sidemenu`
`topmenu`
|
`sidemenu`
|
| layout | Sider Layout |
`sidemenu`
`topmenu`
|
`sidemenu`
|
| primaryColor | Primary color (
*
development only) |
`#1890ff`
| |
| primaryColor | Primary color (
*
development only) |
`#1890ff`
| |
README.zh-CN.md
View file @
628c9f12
...
@@ -132,6 +132,6 @@ export default {
...
@@ -132,6 +132,6 @@ export default {
| Property | Description | Type | Default Value |
| Property | Description | Type | Default Value |
| ---- | ---- | ---- | ---- |
| ---- | ---- | ---- | ---- |
|
navT
heme | 主题 |
`dark`
`light`
`realDark`
|
`light`
|
|
t
heme | 主题 |
`dark`
`light`
`realDark`
|
`light`
|
| layout | 布局模式 |
`sidemenu`
`topmenu`
|
`sidemenu`
|
| layout | 布局模式 |
`sidemenu`
`topmenu`
|
`sidemenu`
|
| primaryColor | 主色调 (
*
仅开发环境生效) |
`#1890ff`
| |
| primaryColor | 主色调 (
*
仅开发环境生效) |
`#1890ff`
| |
src/components/SettingDrawer/index.jsx
View file @
628c9f12
...
@@ -133,7 +133,7 @@ const genCopySettingJson = (settings) =>
...
@@ -133,7 +133,7 @@ const genCopySettingJson = (settings) =>
)
)
export
const
settings
=
{
export
const
settings
=
{
navT
heme
:
PropTypes
.
oneOf
([
'dark'
,
'light'
,
'realDark'
]),
t
heme
:
PropTypes
.
oneOf
([
'dark'
,
'light'
,
'realDark'
]),
primaryColor
:
PropTypes
.
string
,
primaryColor
:
PropTypes
.
string
,
layout
:
PropTypes
.
oneOf
([
'sidemenu'
,
'topmenu'
]),
layout
:
PropTypes
.
oneOf
([
'sidemenu'
,
'topmenu'
]),
colorWeak
:
PropTypes
.
bool
,
colorWeak
:
PropTypes
.
bool
,
...
@@ -166,7 +166,7 @@ const SettingDrawer = {
...
@@ -166,7 +166,7 @@ const SettingDrawer = {
}
=
this
}
=
this
const
{
const
{
navT
heme
=
'dark'
,
t
heme
=
'dark'
,
primaryColor
=
'daybreak'
,
primaryColor
=
'daybreak'
,
layout
=
'sidemenu'
,
layout
=
'sidemenu'
,
fixedHeader
=
false
,
fixedHeader
=
false
,
...
@@ -220,7 +220,7 @@ const SettingDrawer = {
...
@@ -220,7 +220,7 @@ const SettingDrawer = {
</
template
>
</
template
>
<
div
class=
{
`${baseClassName}-content`
}
>
<
div
class=
{
`${baseClassName}-content`
}
>
<
Body
title=
{
i18n
(
'app.setting.pagestyle'
)
}
>
<
Body
title=
{
i18n
(
'app.setting.pagestyle'
)
}
>
<
BlockCheckbox
list=
{
themeList
.
themeList
}
value=
{
navT
heme
}
onChange=
{
(
val
)
=>
{
<
BlockCheckbox
list=
{
themeList
.
themeList
}
value=
{
t
heme
}
onChange=
{
(
val
)
=>
{
changeSetting
(
'theme'
,
val
)
changeSetting
(
'theme'
,
val
)
}
}
/>
}
}
/>
</
Body
>
</
Body
>
...
@@ -228,7 +228,7 @@ const SettingDrawer = {
...
@@ -228,7 +228,7 @@ const SettingDrawer = {
<
ThemeColor
<
ThemeColor
title=
{
i18n
(
'app.setting.themecolor'
)
}
title=
{
i18n
(
'app.setting.themecolor'
)
}
value=
{
primaryColor
}
value=
{
primaryColor
}
colors=
{
themeList
.
colorList
[
navT
heme
===
'realDark'
?
'dark'
:
'light'
]
}
colors=
{
themeList
.
colorList
[
t
heme
===
'realDark'
?
'dark'
:
'light'
]
}
onChange=
{
(
color
)
=>
{
onChange=
{
(
color
)
=>
{
changeSetting
(
'primaryColor'
,
color
,
null
)
changeSetting
(
'primaryColor'
,
color
,
null
)
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment