Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement update for changing the tag labels color in the UI #228

Conversation

yooplo
Copy link

@yooplo yooplo commented Nov 5, 2024

Changes include:

  • updating the default color to something slightly darker
  • removing the category from the tag label
  • changing the tag label color to the category color

Example look:
image

Closes #227

Changes include:
- updating the default color to something slightly darker
- removing the category from the tag label
- changing the tag label color to the category color
@yooplo yooplo added this to the v1.5 milestone Nov 5, 2024
@yooplo yooplo added priority.Medium Nice to have alpha-bug Used for Alpha Test labels Nov 5, 2024
@yooplo yooplo self-assigned this Nov 5, 2024
Copy link

codecov bot commented Nov 5, 2024

Codecov Report

Attention: Patch coverage is 12.50000% with 7 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/main/java/seedu/address/ui/PersonCard.java 0.00% 7 Missing ⚠️
Files with missing lines Coverage Δ Complexity Δ
...main/java/seedu/address/model/tag/TagCategory.java 94.11% <100.00%> (ø) 8.00 <0.00> (ø)
src/main/java/seedu/address/ui/PersonCard.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)

Copy link

@KrashKart KrashKart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@@ -6,7 +6,7 @@
* Provides categories to sort Tags into, as well as colour codes for display in the UI.
*/
public enum TagCategory {
GENERAL("#ECECEC"), // Light Grey for default color
GENERAL("#A9A9A9"), // Dark Grey for default color

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if dark grey is a good colour because it could mean "invalid tag" to a user that's not familiar to our codebase, but I think it suffices for now

tagLabel.setStyle("-fx-padding: 2; -fx-background-color: " + tag.getTagColour());
tags.getChildren().add(tagLabel);
});
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice implementation to refresh the tag status of the tags!

@KrashKart KrashKart self-requested a review November 5, 2024 07:19
@KrashKart KrashKart merged commit 49ca26f into AY2425S1-CS2103T-F14a-4:master Nov 5, 2024
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
alpha-bug Used for Alpha Test priority.Medium Nice to have
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update tag labels to have color syncing in UI Persons List
2 participants