-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Figur out how to do "time-boxed" entries to the banner #4380
Comments
@svrnm can someone assign this one to me? |
To ensure that banner entries are only displayed until their relevant end date, we could define the End Date for each Banner entry. - title: "New Event"
url: "https://example.com/new-event"
message: "Join our new event until May 20th!"
endDate: 2023-05-20
- title: "OTel Community Day"
url: "https://sessionize.com/OTel-Community-Day/"
message: "Join us for OTel Community Day on June 25th!"
endDate: 2023-06-25
- title: "OTel and Prometheus Survey"
url: "https://forms.gle/bZAG9f7udoJsjZUG9"
message: "Help improve OTel and Prometheus interoperability: complete our survey by May 31"
endDate: 2023-05-31 Option 1: Then we will need to modify the banner display logic in
Option 2: if we also want to implement other logic, where the website banner shows the two entries with the closest end dates, we could follow this example that uses Sort and Filter and limits display using the
A consideration to take is that over time, Opinions, thoughts, suggestions? |
I prefer Option 2, since we should limit the number of banner entries, 2 is what we do max right now. Would you mind raising a PR for this such that we can see a preview of that? Maybe add some outdated example entries and some examples in the future to see the logic working. Note that we do not assign issues, just raise the PR and by that you are the one working on that. @chalin wdyt? |
Overall, I prefer option 2, but with these changes:
Thoughts? |
@chalin thanks, sounds good to me, @ricardoamaro please take a look at @chalin's comment and if possible add it to your PR #4429 |
In our banner we most entries are time-bound (e.g KubeCon, GC-election, an end user SIG event, etc.), and sometimes we forget about those entries and they stay in the banner for way to long.
I suggest that we add a feature where we time-box those entries with some hugo code, e.g. something like
Using time functions this should be fairly easy to figure out. There are 2 advanced features we might doing at the same time:
The text was updated successfully, but these errors were encountered: