-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: update link display logic in tooltip
affects: @gio-design/components, website
- Loading branch information
lihang
committed
Jul 21, 2020
1 parent
e220f5c
commit fc6b207
Showing
4 changed files
with
44 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
packages/website/src/components/basic/tooltip/demo/link.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import React from 'react'; | ||
import { Tooltip } from '@gio-design/components'; | ||
import '@gio-design/components/es/components/tooltip/style/index.css'; | ||
|
||
export default () => ( | ||
<> | ||
<Tooltip | ||
title="这里是提示文案。" | ||
tooltipLink={{ name: '点击这里', link: 'www.growingio.com' }} | ||
> | ||
<span className="tooltipSpan" style={{ margin: '0 10px' }}> | ||
TopLeft | ||
</span> | ||
</Tooltip> | ||
<Tooltip | ||
title="这里是提示文案。" | ||
tooltipLink={{ link: 'www.growingio.com' }} | ||
> | ||
<span className="tooltipSpan" style={{ margin: '0 10px' }}> | ||
TopLeft | ||
</span> | ||
</Tooltip> | ||
<Tooltip title="这里是提示文案。" tooltipLink={{ name: '点击这里' }}> | ||
<span className="tooltipSpan" style={{ margin: '0 10px' }}> | ||
TopLeft | ||
</span> | ||
</Tooltip> | ||
</> | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters