From e2e3b36f287cedce98aec43e67b0273d86669104 Mon Sep 17 00:00:00 2001 From: axpoems <145597137+axpoems@users.noreply.github.com> Date: Fri, 31 Jan 2025 09:15:37 +0100 Subject: [PATCH 1/2] Center metrics in profile overview --- .../user/profile_card/overview/ProfileCardOverviewView.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/user/profile_card/overview/ProfileCardOverviewView.java b/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/user/profile_card/overview/ProfileCardOverviewView.java index 536c0648d8..51aae26cb4 100644 --- a/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/user/profile_card/overview/ProfileCardOverviewView.java +++ b/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/user/profile_card/overview/ProfileCardOverviewView.java @@ -120,7 +120,9 @@ private VBox createAndGetTitleAndMetricBox(String title, Label detailsLabel, Lab unitLabel.getStyleClass().addAll("text-fill-grey-dimmed", "medium-text"); HBox detailsAndUnitHBox = new HBox(3, detailsLabel, unitLabel); detailsAndUnitHBox.setAlignment(Pos.BASELINE_CENTER); - return new VBox(titleLabel, detailsAndUnitHBox); + VBox vBox = new VBox(titleLabel, detailsAndUnitHBox); + vBox.setAlignment(Pos.CENTER); + return vBox; } private Region getLine() { From f7efef906cecfb4a57a384e5917e8f7531722d11 Mon Sep 17 00:00:00 2001 From: axpoems <145597137+axpoems@users.noreply.github.com> Date: Fri, 31 Jan 2025 09:26:48 +0100 Subject: [PATCH 2/2] Allow to open profile card in user selection when single user --- .../desktop/main/content/components/UserProfileSelection.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/components/UserProfileSelection.java b/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/components/UserProfileSelection.java index 5432cf4c80..63d3c3d718 100644 --- a/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/components/UserProfileSelection.java +++ b/apps/desktop/desktop/src/main/java/bisq/desktop/main/content/components/UserProfileSelection.java @@ -257,7 +257,7 @@ private View(Model model, Controller controller, int iconSize, boolean useMateri dropdownMenu.setContent(userProfileDisplay); dropdownMenu.useSpaceBetweenContentAndIcon(); - singleUserProfileDisplay = new UserProfileDisplay(iconSize, false); + singleUserProfileDisplay = new UserProfileDisplay(iconSize, true); singleUserProfileHBox = new HBox(singleUserProfileDisplay); singleUserProfileHBox.getStyleClass().add("single-user-profile"); singleUserProfileHBox.setFillHeight(true); @@ -282,7 +282,7 @@ protected void onViewAttached() { selectedUserProfilePin = EasyBind.subscribe(model.getSelectedUserIdentity(), selectedUserIdentity -> { userProfileDisplay.setUserProfile(selectedUserIdentity.getUserProfile(), false); userProfileDisplay.setReputationScore(model.getUserReputationScore()); - singleUserProfileDisplay.setUserProfile(selectedUserIdentity.getUserProfile(), false); + singleUserProfileDisplay.setUserProfile(selectedUserIdentity.getUserProfile(), true); singleUserProfileDisplay.setReputationScore(model.getUserReputationScore()); model.getUserProfiles().forEach(userProfileMenuItem -> userProfileMenuItem.updateSelection(selectedUserIdentity.equals(userProfileMenuItem.getUserIdentity())));