Skip to content

Conversation

rctneil
Copy link
Contributor

@rctneil rctneil commented Mar 4, 2025

Description

Create a new default type for Discreet Information called :id that shows the ID in the header area rather than having to have a field. Also adds an as_badge option to be able to display items up there as badges. Used by the :id type.

My first actual tweak that I know is simple but I hope you like!

Fixes # (issue)

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

Screenshots & recording

Screenshot 2025-03-04 at 21 20 35

Manual review steps

  1. Step 1
  2. Step 2

Manual reviewer: please leave a comment with output from the test if that's the case.

Copy link

qlty-cloud-legacy bot commented Mar 4, 2025

Code Climate has analyzed commit e46cc30 and detected 0 issues on this pull request.

View more on Code Climate.

@rctneil rctneil changed the title Add as_badge and :id type to Discreet Information feature: Add as_badge and :id type to Discreet Information Mar 4, 2025
@adrianthedev
Copy link
Collaborator

@rctneil awesome work! great idea with the :id modifier 🙌

Can you please make the badge smaller so it fits better and post an updated screenshot.

rctneil added 3 commits March 7, 2025 11:36
- Add badged version of timestamps modifier
- Allow id modifier to not always use a badge
- Make badged items as small as possible
@rctneil
Copy link
Contributor Author

rctneil commented Mar 7, 2025

@rctneil awesome work! great idea with the :id modifier 🙌

Can you please make the badge smaller so it fits better and post an updated screenshot.

Hi @adrianthedev I've made some changes. I tried to make the badged items as small as possible. Had to reduce the icon size if they are badged. Also tweaked colours so they are more subtle. Also added variants of :id and :timestamps as :id_badged and :timestamps_badged.

Screenshot 2025-03-07 at 11 35 09

Changes:

  • Add badged version of timestamps modifier
  • Allow id modifier to not always use a badge
  • Make badged items as small as possible
  • Tweaked colours to be more subtle

Do let me know your thoughts!

@adrianthedev Unsure what happened with the last commit. Not sure why that is there? I do apologise that my got knowledge is very hazy. :-/

@adrianthedev adrianthedev merged commit e46cc30 into avo-hq:main Mar 13, 2025
20 checks passed
@adrianthedev
Copy link
Collaborator

Hey @rctneil thanks for sending this in.

I don't exactly know how this happened, but I wanted to push some changes to this branch but accidentally pushed to main 🤦‍♂️

I did one change to the API. instead of as_badge I changed it to as: :badge to match the fields declaration and keep it updatable in the future.

Would you mind writing the docs for this feature?

@rctneil
Copy link
Contributor Author

rctneil commented Mar 13, 2025

@adrianthedev

I've just seen the changes. I apologise for not getting it exactly as you wanted. You should have commented and i'd have given it another pass to improve it further.

Sorry again

Ok, i'll look at documentation. Is this just a case of cloning down another repo?

Neil

@adrianthedev
Copy link
Collaborator

No need to apologize, really. There weren't any indications.
That API just came to me when I was playing around with it.

I usually do that, leave a review for changes, but I had a few spare minutes and tried to upload them myself. As you may have noticed I pushed to main by mistake.

The docs are in this repo.
You'll find the special page about discreet information.

Thanks for your contribution!

@rctneil
Copy link
Contributor Author

rctneil commented Mar 13, 2025

@adrianthedev Ok, docs are submitted. I hope i've done that right.

Really excited to see my changes in a public release. As I said, my git knowledge is kinda flimsy so just trying to work through it.

I hope people like this small tweak to the excellent discreet information feature!

@Paul-Bob Paul-Bob added the Enhancement Not necessarily a feature, but something has improved label Mar 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Not necessarily a feature, but something has improved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants