Skip to content

Commit

Permalink
reformatted MapleHyperlink.kt
Browse files Browse the repository at this point in the history
  • Loading branch information
SpoilerRules committed Jul 26, 2024
1 parent 7f2a99b commit d1d8bc9
Showing 1 changed file with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,23 +41,23 @@ fun MapleHyperlink(
color = textColor,
style = TextStyle(fontFamily = fontFamily, fontWeight = fontWeight, fontSize = fontSize),
modifier =
Modifier.baseHoverColor(color) { modifiedColor ->
textColor =
if (isHovered) {
modifiedColor
} else {
color
}
}
.pointerHoverIcon(PointerIcon.Hand)
.onClick {
runCatching {
uriHandler.openUri(url)
Logger.printSuccess("Link opened successfully: $url")
}.onFailure { error ->
Logger.printError("Failed to open link: $url - ${error.message}")
}
Modifier.baseHoverColor(color) { modifiedColor ->
textColor =
if (isHovered) {
modifiedColor
} else {
color
}
}
.onHover { isHovered = it },
.pointerHoverIcon(PointerIcon.Hand)
.onClick {
runCatching {
uriHandler.openUri(url)
Logger.printSuccess("Link opened successfully: $url")
}.onFailure { error ->
Logger.printError("Failed to open link: $url - ${error.message}")
}
}
.onHover { isHovered = it },
)
}

0 comments on commit d1d8bc9

Please sign in to comment.