fix: Wakatime compact card display#4435
Conversation
…g in Wakatime cards.
…r improved spacing
|
@bbbugg is attempting to deploy a commit to the github readme stats Team on Vercel. A member of the Team first needs to authorize it. |
qwerty541
left a comment
There was a problem hiding this comment.
Hello @bbbugg
Thank you for opening pull request. I appreciate you interest in our project.
Regarding the changes, the wakatime card works as is for years and thousands of users are okay with current behavior. This means that we definitely should not change the default baviour of the card. For preventing users to experience unexpected changes in their profiles withour actions from their side let's keep it as is.
However, I'm open to consider the addition of new query string parameter, for example &ordering=horizontal | vertical, to provide more customization ways for users who really wants it.
Also I didn't get the changes related to the line height, I would be grateful in case you can explain in more details.
@qwerty541 Thank you for your review! About the line height changes: Previously, both the line spacing and the overall card height were determined by a fixed value of 25, so the line_height parameter had no real effect. In this PR, the spacing between lines and the card height are now both dynamically calculated based on the line_height parameter, making it actually functional. Additionally, the ordering logic has been refactored to use the All changes can be demonstrated through the examples on the top. |
…s (horizontal/vertical)
# Conflicts: # src/cards/wakatime.js
# Conflicts: # src/cards/wakatime.js
…width and line height
|
Hi @qwerty541, Could you please take a look at this PR when you have a chance? Thanks |
This pull request updates the layout logic for rendering the compact Wakatime card, focusing on improving the spacing and alignment of language nodes. The main changes introduce a configurable
lineHeightparameter, ensuring better vertical spacing and more maintainable code when displaying language statistics.What’s changed
horizontal.Examples
Horizontal ordering:
Vertical ordering:
Larger line height (35):
Smaller line height (15):