Skip to content

fix: re-design DateRangeFilter#18924

Merged
eunjae-lee merged 5 commits intomainfrom
eunjae/cal-5073-re-design-date-range-picker
Jan 29, 2025
Merged

fix: re-design DateRangeFilter#18924
eunjae-lee merged 5 commits intomainfrom
eunjae/cal-5073-re-design-date-range-picker

Conversation

@eunjae-lee
Copy link
Copy Markdown
Contributor

@eunjae-lee eunjae-lee commented Jan 27, 2025

What does this PR do?

This PR re-designs DateRangeFilter, so that it combines Select and DateRangePicker altogether, and shows DateRangePicker only for "custom" range.

  • Fixes CAL-5073

Before

Screenshot.2025-01-27.at.17.54.13.mp4

After

Screenshot.2025-01-27.at.17.57.00.mp4

Mandatory Tasks (DO NOT REMOVE)

  • I have self-reviewed the code (A decent size PR without self-review might be rejected).
  • N/A - I have updated the developer docs in /docs if this PR makes changes that would require a documentation change. If N/A, write N/A here and check the checkbox.
  • I confirm automated tests are in place that prove my fix is effective or that my feature works.

How should this be tested?

Test the date range picker on /insights/routing.

@vercel
Copy link
Copy Markdown

vercel Bot commented Jan 27, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
cal ⬜️ Ignored (Inspect) Visit Preview Jan 29, 2025 4:16pm
calcom-web-canary ⬜️ Ignored (Inspect) Visit Preview Jan 29, 2025 4:16pm

@linear
Copy link
Copy Markdown

linear Bot commented Jan 27, 2025

@keithwillcode keithwillcode added consumer core area: core, team members only labels Jan 27, 2025
@eunjae-lee eunjae-lee marked this pull request as ready for review January 27, 2025 16:59
@graphite-app graphite-app Bot requested a review from a team January 27, 2025 16:59
@dosubot dosubot Bot added insights area: insights, analytics 🧹 Improvements Improvements to existing features. Mostly UX/UI labels Jan 27, 2025
@graphite-app
Copy link
Copy Markdown

graphite-app Bot commented Jan 27, 2025

Graphite Automations

"Add consumer team as reviewer" took an action on this PR • (01/27/25)

1 reviewer was added to this PR based on Keith Williams's automation.

"Add ready-for-e2e label" took an action on this PR • (01/29/25)

1 label was added to this PR based on Keith Williams's automation.

Comment on lines +198 to +215
<Command className="w-40">
<CommandList>
{PRESET_OPTIONS.map((option) => (
<CommandItem
key={option.value}
className={classNames(
"cursor-pointer justify-between",
selectedPreset.value === option.value && "bg-emphasis"
)}
onSelect={() => {
updateDateRangeFromPreset(option.value);
}}>
<span className="capitalize">{t(option.labelKey, option.i18nOptions)}</span>
{selectedPreset.value === option.value && <Icon name="check" />}
</CommandItem>
))}
</CommandList>
</Command>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NIT: Can we double check the styling of this section - seems like we should have a bit of padding and gap between elements <3

@eunjae-lee
Copy link
Copy Markdown
Contributor Author

eunjae-lee commented Jan 28, 2025

adjusted paddings

This PR

Screenshot 2025-01-28 at 11 28 39

Prod (for comparison)

Screenshot 2025-01-28 at 11 29 18

@eunjae-lee eunjae-lee enabled auto-merge (squash) January 28, 2025 10:39
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jan 29, 2025

E2E results are ready!

@eunjae-lee eunjae-lee merged commit 5c98861 into main Jan 29, 2025
@eunjae-lee eunjae-lee deleted the eunjae/cal-5073-re-design-date-range-picker branch January 29, 2025 16:41
MuhammadAimanSulaiman pushed a commit to hit-pay/cal.com that referenced this pull request Feb 25, 2025
* fix: re-design DateRangeFilter

* update style

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

Labels

consumer core area: core, team members only 🧹 Improvements Improvements to existing features. Mostly UX/UI insights area: insights, analytics ready-for-e2e

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants