Tencent / Tencent/tdesign-react

[Tooltip] 添加控制每次Tooltip显示时间的API

Open
#3,059 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

💪🏻 enhancement
Dominant language
TypeScript
Stars
965
Forks
373
Avg merge
3d 6h
Merged PRs (30d)
17

Description

这个功能解决了什么问题

当前Tooltip有API:duration-用于设置提示默认显示多长时间之后消失,但其会导致tooltip在初次渲染时出现,如果不希望组件在初次渲染时出现,但又需要控制每次显示的时间,则不能使用该属性。

你建议的方案是什么

建议增加API以控制Tooltip的显示时间,例如点击后显示,显示n秒后消失。

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the Tooltip component's existing duration API and its initial-render behavior. Compare the requested click-to-show, timed-dismissal behavior with the current API, then clarify the new API semantics and verify that both initial rendering and repeated displays behave as intended.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.