Tabs now use InstantTooltip

This commit is contained in:
Abdelilah El Aissaoui 2024-01-12 15:14:02 +01:00
parent 9b75e0d804
commit 8a65a56f75
No known key found for this signature in database
GPG Key ID: 7587FC860F594869
2 changed files with 3 additions and 3 deletions

View File

@ -28,7 +28,7 @@ import com.jetpackduba.gitnuro.theme.isDark
@Composable
fun InstantTooltip(
text: String,
text: String?,
modifier: Modifier = Modifier,
position: InstantTooltipPosition = InstantTooltipPosition.BOTTOM,
content: @Composable () -> Unit,
@ -47,7 +47,7 @@ fun InstantTooltip(
content()
}
if (isHovered && coordinates != null) {
if (isHovered && coordinates != null && text != null) {
Popup(
properties = PopupProperties(
focusable = false,

View File

@ -118,7 +118,7 @@ fun RepositoriesTabPanel(
key = { _, tab -> tab.tabViewModel }
) { index, tab ->
HorizontalDraggableItem(dragDropState, index) { _ ->
Tooltip(tab.path) {
InstantTooltip(tab.path) {
Tab(
modifier = Modifier,
title = tab.tabName,