Expose Hyperlink looked-up color variables
This commit is contained in:
parent
465f199911
commit
38a5d73a3b
@ -244,9 +244,14 @@ public class TypographyPage extends AbstractPage {
|
||||
var linkVisited = hyperlink("_Visited", true, false);
|
||||
linkVisited.setMnemonicParsing(true);
|
||||
|
||||
var linkBroken = hyperlink("_Broken", true, false);
|
||||
linkBroken.setStyle("-color-link-fg-visited:-color-danger-fg;");
|
||||
linkBroken.setMnemonicParsing(true);
|
||||
|
||||
var box = new HBox(10,
|
||||
linkNormal,
|
||||
linkVisited,
|
||||
linkBroken,
|
||||
hyperlink("Disabled", false, true)
|
||||
);
|
||||
box.setAlignment(Pos.BASELINE_LEFT);
|
||||
|
@ -2,17 +2,26 @@
|
||||
|
||||
@use "../settings/config"as cfg;
|
||||
|
||||
$color-fg: -color-accent-fg !default;
|
||||
$color-fg-visited: -color-fg-default !default;
|
||||
$color-fg-armed: -color-fg-default !default;
|
||||
|
||||
.hyperlink {
|
||||
|
||||
-color-link-fg: $color-fg;
|
||||
-color-link-fg-visited: $color-fg-visited;
|
||||
-color-link-fg-armed: $color-fg-armed;
|
||||
|
||||
-fx-cursor: hand;
|
||||
-fx-underline: true;
|
||||
-fx-text-fill: -color-accent-fg;
|
||||
-fx-text-fill: -color-link-fg;
|
||||
|
||||
&:visited {
|
||||
-fx-text-fill: -color-fg-default;
|
||||
-fx-text-fill: -color-link-fg-visited;
|
||||
}
|
||||
|
||||
&:armed {
|
||||
-fx-text-fill: -color-fg-default;
|
||||
-fx-text-fill: -color-link-fg-armed;
|
||||
-fx-underline: false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user