Skip to content

soft_start_date#414

Draft
Danysan1 wants to merge 16 commits into
osm-fr:mainfrom
Danysan1:feature/USE_SOFT_DATES
Draft

soft_start_date#414
Danysan1 wants to merge 16 commits into
osm-fr:mainfrom
Danysan1:feature/USE_SOFT_DATES

Conversation

@Danysan1
Copy link
Copy Markdown
Contributor

@Danysan1 Danysan1 commented Mar 1, 2026

In the italian instance we are representing single-month-long projects but we need to also show the history of tagging in the months right before and after the month.
This is a draft of changes I'm implementing to allow this, specifically:

  • add the soft_start_date option to the project config, allowing to specify the beginning of the strong community involvement period. The only required date option would remain start_date, if all four are configured they should be in the order start_date < soft_start_date < soft_end_date < end_date. If the two soft dates are specified, their range is automatically highlighted on the chart (see screenshots below)
  • add the USE_SOFT_DATES boolean option to the site config, which if true makes the site use soft_start_date and soft_end_date to calculate whether each project is past, current or next (which changes how it's shown in the homepage and what's shown at the top of the project page)
  • if USE_SOFT_DATES=true all statistics of the project page should show the statistics for only the soft_start_date - soft_end_date range, instead (or alongside) the statistics for the full history
  • if USE_SOFT_DATES=true use soft_start_date and soft_end_date range for badge calculations

Do you have feedback on the current changes or suggestions on the remaining changes?

Examples:
https://osmit-podoma.wmcloud.org/projects/2025-12_ithydrant
Screenshot 2026-03-01 203412
photo_2026-03-01_21-39-14

https://osmit-podoma.wmcloud.org/projects/2025-07_ittownhall
Screenshot 2026-03-01 203303
photo_2026-03-01_21-39-16

Danysan1 added 3 commits March 1, 2026 21:07
(cherry picked from commit b20b28dcf59a2dc99ccf852b73e100c42135997f)
@PanierAvide
Copy link
Copy Markdown
Collaborator

This is amazing ! I wasn't aware that Chart.js offered plugins allowing to do that, I looked a bit in the past to have this kind of highlight but didn't manage to implement it. Changes & docs are looking good for now, glad to see the rest of it 😀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants