Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dify
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
ai-tech
dify
Commits
a45ec15a
Commit
a45ec15a
authored
Mar 06, 2024
by
StyleZhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
features
parent
0164dec4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
index.tsx
web/app/components/base/features/feature-choose/index.tsx
+8
-2
No files found.
web/app/components/base/features/feature-choose/index.tsx
View file @
a45ec15a
...
@@ -5,8 +5,14 @@ import { useFeatures } from '../hooks'
...
@@ -5,8 +5,14 @@ import { useFeatures } from '../hooks'
import
FeatureModal
from
'./feature-modal'
import
FeatureModal
from
'./feature-modal'
import
Button
from
'@/app/components/base/button'
import
Button
from
'@/app/components/base/button'
import
{
Plus02
}
from
'@/app/components/base/icons/src/vender/line/general'
import
{
Plus02
}
from
'@/app/components/base/icons/src/vender/line/general'
import
type
{
Features
}
from
'@/app/components/base/features/types'
const
ChooseFeature
=
()
=>
{
type
ChooseFeatureProps
=
{
onChange
?:
(
features
:
Features
)
=>
void
}
const
ChooseFeature
=
({
onChange
,
}:
ChooseFeatureProps
)
=>
{
const
{
t
}
=
useTranslation
()
const
{
t
}
=
useTranslation
()
const
showFeaturesModal
=
useFeatures
(
s
=>
s
.
showFeaturesModal
)
const
showFeaturesModal
=
useFeatures
(
s
=>
s
.
showFeaturesModal
)
const
setShowFeaturesModal
=
useFeatures
(
s
=>
s
.
setShowFeaturesModal
)
const
setShowFeaturesModal
=
useFeatures
(
s
=>
s
.
setShowFeaturesModal
)
...
@@ -21,7 +27,7 @@ const ChooseFeature = () => {
...
@@ -21,7 +27,7 @@ const ChooseFeature = () => {
</
Button
>
</
Button
>
{
{
showFeaturesModal
&&
(
showFeaturesModal
&&
(
<
FeatureModal
/>
<
FeatureModal
onChange=
{
onChange
}
/>
)
)
}
}
</>
</>
...
...
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