* 移除现有的提示弹窗
()
| 881 | * 移除现有的提示弹窗 |
| 882 | */ |
| 883 | function removeExistingTooltip(): void { |
| 884 | const existing = document.getElementById('fluent-input-translation-tooltip'); |
| 885 | if (existing) { |
| 886 | if (!config.animations) { |
| 887 | // 如果禁用动画,直接移除 |
| 888 | existing.remove(); |
| 889 | } else { |
| 890 | // 使用淡出动画 |
| 891 | existing.classList.add('hide'); |
| 892 | setTimeout(() => existing.remove(), 300); |
| 893 | } |
| 894 | } |
| 895 | } |
| 896 | |
| 897 | /** |
| 898 | * 添加输入框动画效果 |
no outgoing calls
no test coverage detected