Tabs now use InstantTooltip
This commit is contained in:
parent
9b75e0d804
commit
8a65a56f75
@ -28,7 +28,7 @@ import com.jetpackduba.gitnuro.theme.isDark
|
|||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun InstantTooltip(
|
fun InstantTooltip(
|
||||||
text: String,
|
text: String?,
|
||||||
modifier: Modifier = Modifier,
|
modifier: Modifier = Modifier,
|
||||||
position: InstantTooltipPosition = InstantTooltipPosition.BOTTOM,
|
position: InstantTooltipPosition = InstantTooltipPosition.BOTTOM,
|
||||||
content: @Composable () -> Unit,
|
content: @Composable () -> Unit,
|
||||||
@ -47,7 +47,7 @@ fun InstantTooltip(
|
|||||||
content()
|
content()
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isHovered && coordinates != null) {
|
if (isHovered && coordinates != null && text != null) {
|
||||||
Popup(
|
Popup(
|
||||||
properties = PopupProperties(
|
properties = PopupProperties(
|
||||||
focusable = false,
|
focusable = false,
|
||||||
|
@ -118,7 +118,7 @@ fun RepositoriesTabPanel(
|
|||||||
key = { _, tab -> tab.tabViewModel }
|
key = { _, tab -> tab.tabViewModel }
|
||||||
) { index, tab ->
|
) { index, tab ->
|
||||||
HorizontalDraggableItem(dragDropState, index) { _ ->
|
HorizontalDraggableItem(dragDropState, index) { _ ->
|
||||||
Tooltip(tab.path) {
|
InstantTooltip(tab.path) {
|
||||||
Tab(
|
Tab(
|
||||||
modifier = Modifier,
|
modifier = Modifier,
|
||||||
title = tab.tabName,
|
title = tab.tabName,
|
||||||
|
Loading…
Reference in New Issue
Block a user