Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
submodule
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
web_component
submodule
Commits
51b09f3d
Commit
51b09f3d
authored
Jun 15, 2020
by
zhangwenshuai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
f3cf7e75
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
index.tsx
...ents/apolloTable/component/base/detail/textarea/index.tsx
+9
-2
No files found.
components/apolloTable/component/base/detail/textarea/index.tsx
View file @
51b09f3d
...
...
@@ -11,6 +11,9 @@ export const ApolloTextAreaDetail = (props: TextAreaProps) => {
return
null
;
}
const
[
value
,
setValue
]
=
useState
(
formatValue
);
useEffect
(()
=>
{
setValue
(
formatValue
);
},
[
formatValue
]);
const
{
cutLength
,
getDetail
}
=
componentAttr
;
const
[
dotVisible
,
setDotVisible
]
=
useState
(
false
);
const
container
=
useRef
(
null
);
...
...
@@ -44,11 +47,15 @@ export const ApolloTextAreaDetail = (props: TextAreaProps) => {
<
div
className=
{
styles
.
container
}
ref=
{
container
}
>
{
dotVisible
?
(
<
Tooltip
overlayClassName=
{
styles
.
tooltip
}
overlayClassName=
{
styles
.
tooltip
}
title=
{
<
div
className=
{
styles
.
tooltipTitle
}
>
{
value
}
{
value
.
length
===
cutLength
&&
<
span
className=
{
styles
.
more
}
onClick=
{
getMore
}
>
查看更多
</
span
>
}
{
value
.
length
===
cutLength
&&
(
<
span
className=
{
styles
.
more
}
onClick=
{
getMore
}
>
查看更多
</
span
>
)
}
</
div
>
}
>
...
...
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