lsd icon indicating copy to clipboard operation
lsd copied to clipboard

Fixed icons alignment of various rendered width

Open ehwan opened this issue 1 year ago • 1 comments

For #1054. Fixed icons to be right aligned.

Before

image image image

After

image image image

I'm not sure if it is OK to force right-align icons, but I think it is the simplest solution.

  • This follows the same logic as aligning 'Block::Size' or 'Block::SizeValue'.
  • However, for --tree, icons are aligned within same level of entries. If all entries in a directory have icons of width 1, no padding will be added even if there are icons with longer widths outside.

TODO

  • [x] Use cargo fmt
  • [x] Add necessary tests
  • [x] Update default config/theme in README (if applicable)
  • [x] Update man page at lsd/doc/lsd.md (if applicable)

ehwan avatar Jun 22 '24 13:06 ehwan

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: ehwan Once this PR has been reviewed and has the lgtm label, please assign zwpaper for approval by writing /assign @zwpaper in a comment. For more information see:The Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

muniu-bot[bot] avatar Jun 22 '24 13:06 muniu-bot[bot]