-
Notifications
You must be signed in to change notification settings - Fork 35
feat(timeline-picker): implement basic timeline picker #101
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
Conversation
9a6e14c to
b885ccc
Compare
|
Oh nice! I'm happy to review when it's ready |
This is the first commit, the fork action is not yet implemented
Format the time as and highlight it as well as align it to the right
320e7ef to
b83ba30
Compare
|
If you want to have a look, it's almost ready |
5385c8e to
095f47c
Compare
|
Great, I'll take a look today |
|
Had a few mins and tried to play around with it but ran into some early errors:
Removing the "lua." does let me open the picker. I'll take a closer look but wanted to share those issues in case they were already on your radar. |
cameronr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's coming along really nicely!
My only suggestion is that we should do some more work on how the pickers format their text:
- Dates should be right aligned consistently across the picker providers
- I wonder if there's an opportunity for a more condensed date format, maybe it's "Oct 05 14:23" if it's this year, and "2024-10-05 14:23" if not?
I will soon have a refactored picker that both sessions and timeline can use. It will be much easier to create new ones |
Great idea. For the alignment. I need to find a way to get the picker width. |
This creates a base picker module to make it as easy as possible to create new ones with the same pattern It also aligns the date to the right properly for every picker
I did some work on having the dates align on all pickers. Unfortunately some pickers construct their list before showing the window so getting the with was not possible. I ended up fixing the with of the picker instead with a config, It works pretty well with some edges cases where telescope and fzf have somme padding in their default theme. I added a padding offset for theeses pickers. It should be good enough. |
5a76194 to
b7fd9ef
Compare
|
Oh shoot, I just saw your update to set the snacks layout widths. I'll undo the the snacks width changes. |
89e8a49 to
615d0d3
Compare
|
Ok, so now my changes are just fixing snacks matching and using the actual time for width calculation. Everything else looks good. Really nicely done! |
|
Thanks for your fixes. I will merge this pretty soon |









This implement a simple timeline pcker similar to the one found in opencode tui
