Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
VisualDL
提交
96fb036b
V
VisualDL
项目概览
PaddlePaddle
/
VisualDL
大约 2 年 前同步成功
通知
89
Star
4655
Fork
642
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
5
Wiki
分析
仓库
DevOps
项目成员
Pages
V
VisualDL
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
5
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
96fb036b
编写于
6月 22, 2022
作者:
R
RotPublic
提交者:
GitHub
6月 22, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix textview bug
上级
fbb72b74
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
53 addition
and
51 deletion
+53
-51
frontend/packages/core/src/components/SamplePage/ImagePreviewer.tsx
...ackages/core/src/components/SamplePage/ImagePreviewer.tsx
+1
-1
frontend/packages/core/src/components/SamplePage/Text.tsx
frontend/packages/core/src/components/SamplePage/Text.tsx
+52
-50
未找到文件。
frontend/packages/core/src/components/SamplePage/ImagePreviewer.tsx
浏览文件 @
96fb036b
...
@@ -191,7 +191,7 @@ const ImagePreviewer: FunctionComponent<ImagePreviewerProps> = ({
...
@@ -191,7 +191,7 @@ const ImagePreviewer: FunctionComponent<ImagePreviewerProps> = ({
setWidth
(
ir
*
rect
.
height
*
0.9
);
setWidth
(
ir
*
rect
.
height
*
0.9
);
}
else
if
(
ir
>=
r
&&
img
.
naturalWidth
>
rect
.
width
*
0.9
)
{
}
else
if
(
ir
>=
r
&&
img
.
naturalWidth
>
rect
.
width
*
0.9
)
{
setWidth
(
rect
.
width
*
0.9
);
setWidth
(
rect
.
width
*
0.9
);
setHeight
(
ir
*
rect
.
width
*
0.9
);
setHeight
(
(
rect
.
width
/
ir
)
*
0.9
);
}
else
{
}
else
{
setWidth
(
img
.
naturalWidth
);
setWidth
(
img
.
naturalWidth
);
setHeight
(
img
.
naturalHeight
);
setHeight
(
img
.
naturalHeight
);
...
...
frontend/packages/core/src/components/SamplePage/Text.tsx
浏览文件 @
96fb036b
...
@@ -104,33 +104,33 @@ const TextWrapper = styled.div`
...
@@ -104,33 +104,33 @@ const TextWrapper = styled.div`
${
sameBorder
(
true
)}
${
sameBorder
(
true
)}
${
transitionProps
(
'
border-color
'
)}
${
transitionProps
(
'
border-color
'
)}
`
;
`
;
// display: grid;
// grid-template-columns: fit-content(25%) auto;
// grid-row-gap: ${rem(12)};
// justify-items: stretch;
// align-items: stretch;
// ${transitionProps('border-color')}
const
TextGrid
=
styled
.
div
`
const
TextGrid
=
styled
.
div
`
margin-top:
${
rem
(
12
)}
;
margin-top:
${
rem
(
12
)}
;
display: grid;
>div {
grid-template-columns: fit-content(25%) auto;
${
sameBorder
()}
grid-row-gap:
${
rem
(
12
)}
;
border-radius:
${
borderRadius
}
;
justify-items: stretch;
margin-bottom:
${
rem
(
20
)}
;
align-items: stretch;
${
transitionProps
(
'
border-color
'
)}
> span {
> span {
display:block;
height:
${
rem
(
40
)}
;
height:
${
rem
(
40
)}
;
line-height: 1.857142857;
line-height: 1.857142857;
padding:
${
rem
(
7
)}
0;
padding:
${
rem
(
7
)}
0;
}
}
.step {
.step {
${
sameBorder
()}
border-right: none;
border-top-left-radius:
${
borderRadius
}
;
border-bottom-left-radius:
${
borderRadius
}
;
padding-left:
${
rem
(
8
)}
;
padding-left:
${
rem
(
8
)}
;
padding-right:
${
rem
(
14
)}
;
padding-right:
${
rem
(
14
)}
;
> span {
> span {
display: block;
display: inline-block;
width: 100%;
width: atuo;
clear:both
color: var(--text-light-color);
color: var(--text-light-color);
background-color: var(--text-chart-tag-background-color);
background-color: var(--text-chart-tag-background-color);
padding: 0
${
rem
(
8
)}
;
padding: 0
${
rem
(
8
)}
;
...
@@ -140,18 +140,20 @@ const TextGrid = styled.div`
...
@@ -140,18 +140,20 @@ const TextGrid = styled.div`
}
}
.text {
.text {
${
sameBorder
()}
padding-left: 1rem;
border-left: none;
border-top-right-radius:
${
borderRadius
}
;
border-bottom-right-radius:
${
borderRadius
}
;
padding-right:
${
rem
(
20
)}
;
padding-right:
${
rem
(
20
)}
;
${
ellipsis
()}
display: block;
overflow: hidden;
white-space: normal;
word-wrap: normal;
height:auto;
> * {
> * {
vertical-align: middle;
vertical-align: middle;
}
}
}
}
`
;
}
`
;
type
TextProps
=
{
type
TextProps
=
{
index
:
number
;
index
:
number
;
...
@@ -171,7 +173,7 @@ const Text: FunctionComponent<TextProps> = ({run, tag, step, wallTime, index}) =
...
@@ -171,7 +173,7 @@ const Text: FunctionComponent<TextProps> = ({run, tag, step, wallTime, index}) =
});
});
return
(
return
(
<>
<
div
>
<
span
className
=
"step"
>
<
span
className
=
"step"
>
<
span
>
<
span
>
{
t
(
'
common:time-mode.step
'
)
}
{
step
}
{
t
(
'
common:time-mode.step
'
)
}
{
step
}
...
@@ -186,7 +188,7 @@ const Text: FunctionComponent<TextProps> = ({run, tag, step, wallTime, index}) =
...
@@ -186,7 +188,7 @@ const Text: FunctionComponent<TextProps> = ({run, tag, step, wallTime, index}) =
error
??
text
error
??
text
)
}
)
}
</
span
>
</
span
>
</>
</
div
>
);
);
};
};
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录