Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
bkunyun
Project
Project
Details
Activity
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
Administrator
bkunyun
Commits
6d5033b9
Commit
6d5033b9
authored
Aug 05, 2022
by
jiangzijing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:添加模板样式
parent
c054d7f8
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
4 deletions
+26
-4
index.module.css
...workbenchTemplate/components/AddTemplate/index.module.css
+2
-2
index.tsx
...kbench/workbenchTemplate/components/AddTemplate/index.tsx
+24
-2
No files found.
src/views/Project/ProjectWorkbench/workbenchTemplate/components/AddTemplate/index.module.css
View file @
6d5033b9
...
@@ -15,8 +15,8 @@
...
@@ -15,8 +15,8 @@
}
}
.templateBox
{
.templateBox
{
padding
:
20px
32px
0
;
padding
:
0
32px
;
height
:
calc
(
100vh
-
1
8
8px
);
height
:
calc
(
100vh
-
1
6
8px
);
overflow
:
auto
;
overflow
:
auto
;
}
}
...
...
src/views/Project/ProjectWorkbench/workbenchTemplate/components/AddTemplate/index.tsx
View file @
6d5033b9
...
@@ -52,6 +52,18 @@ const AddTemplate = (props: IAddTemplateProps) => {
...
@@ -52,6 +52,18 @@ const AddTemplate = (props: IAddTemplateProps) => {
const
[
templateType
,
setTemplateType
]
=
useState
(
"public"
);
const
[
templateType
,
setTemplateType
]
=
useState
(
"public"
);
// 滚轮是否到顶,判断是否显示阴影
const
[
isTop
,
setIsTop
]
=
useState
(
true
)
// 滚动滚轮时监听是否到顶
const
onscroll
=
(
e
:
any
)
=>
{
if
(
e
.
target
.
scrollTop
<=
0
)
{
setIsTop
(
true
)
}
else
{
setIsTop
(
false
)
}
}
const
handleRadio
=
(
value
:
string
)
=>
{
const
handleRadio
=
(
value
:
string
)
=>
{
setTemplateType
(
value
);
setTemplateType
(
value
);
};
};
...
@@ -194,6 +206,12 @@ const AddTemplate = (props: IAddTemplateProps) => {
...
@@ -194,6 +206,12 @@ const AddTemplate = (props: IAddTemplateProps) => {
return
(
return
(
<
FullScreenDrawer
handleClose=
{
setShowAddTemplate
}
>
<
FullScreenDrawer
handleClose=
{
setShowAddTemplate
}
>
<
div
className=
{
style
.
content
}
>
<
div
className=
{
style
.
content
}
>
<
div
className=
{
classNames
({
[
style
.
headerBox
]:
true
,
[
style
.
headerBoxShadow
]:
!
isTop
,
})
}
>
<
Typography
<
Typography
sx=
{
{
fontSize
:
"18px"
,
fontWeight
:
"600"
,
color
:
"#1E2633"
}
}
sx=
{
{
fontSize
:
"18px"
,
fontWeight
:
"600"
,
color
:
"#1E2633"
}
}
>
>
...
@@ -204,7 +222,8 @@ const AddTemplate = (props: IAddTemplateProps) => {
...
@@ -204,7 +222,8 @@ const AddTemplate = (props: IAddTemplateProps) => {
display
:
"flex"
,
display
:
"flex"
,
justifyContent
:
"space-between"
,
justifyContent
:
"space-between"
,
alignItems
:
"center"
,
alignItems
:
"center"
,
marginBottom
:
"20px"
,
paddingBottom
:
"20px"
,
paddingTop
:
"20px"
,
}
}
}
}
>
>
<
OutlinedInput
<
OutlinedInput
...
@@ -214,7 +233,7 @@ const AddTemplate = (props: IAddTemplateProps) => {
...
@@ -214,7 +233,7 @@ const AddTemplate = (props: IAddTemplateProps) => {
}
}
}
}
placeholder=
"输入关键词搜索"
placeholder=
"输入关键词搜索"
size=
"small"
size=
"small"
sx=
{
{
width
:
340
,
height
:
32
,
marginTop
:
"20px"
}
}
sx=
{
{
width
:
340
,
height
:
32
}
}
endAdornment=
{
<
SearchIcon
style=
{
{
color
:
"#8A9099"
}
}
/>
}
endAdornment=
{
<
SearchIcon
style=
{
{
color
:
"#8A9099"
}
}
/>
}
/>
/>
<
Box
<
Box
...
@@ -244,6 +263,8 @@ const AddTemplate = (props: IAddTemplateProps) => {
...
@@ -244,6 +263,8 @@ const AddTemplate = (props: IAddTemplateProps) => {
/> */
}
/> */
}
</
Box
>
</
Box
>
</
Box
>
</
Box
>
</
div
>
<
div
className=
{
style
.
templateBox
}
onScroll=
{
onscroll
}
>
{
templateType
===
"public"
&&
addTemplateList
.
length
===
0
&&
(
{
templateType
===
"public"
&&
addTemplateList
.
length
===
0
&&
(
<
Box
<
Box
sx=
{
{
sx=
{
{
...
@@ -349,6 +370,7 @@ const AddTemplate = (props: IAddTemplateProps) => {
...
@@ -349,6 +370,7 @@ const AddTemplate = (props: IAddTemplateProps) => {
})
}
})
}
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
{
customTemplateInfo
?.
show
?
(
{
customTemplateInfo
?.
show
?
(
<
WorkFlowEdit
<
WorkFlowEdit
id=
{
customTemplateInfo
.
id
||
""
}
id=
{
customTemplateInfo
.
id
||
""
}
...
...
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