Skip to content

chore: 🤖 expose datetimerangepicker component and types to main public api#883

Merged
punkbit merged 8 commits intomainfrom
chore/expose-datetimerangepicker-comp-types-to-main-public-api
Mar 9, 2026
Merged

chore: 🤖 expose datetimerangepicker component and types to main public api#883
punkbit merged 8 commits intomainfrom
chore/expose-datetimerangepicker-comp-types-to-main-public-api

Conversation

@punkbit
Copy link
Collaborator

@punkbit punkbit commented Mar 9, 2026

Why?

Expose DateTimeRangePicker component and related types to the public API.

⚠️ Depends on #882

How?

  • DateTimeRangePicker - A date/time range picker component for selecting date and time ranges
  • DateTimeRangePickerProps - TypeScript props for the DateTimeRangePicker component
  • DateRangePickerProps - TypeScript props for the DateRangePicker component
  • DatePickerProps - TypeScript props for the DatePicker component

Preview?

N/A

@changeset-bot
Copy link

changeset-bot bot commented Mar 9, 2026

⚠️ No Changeset found

Latest commit: 3625bc0

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes changesets to release 1 package
Name Type
@clickhouse/click-ui Minor

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions
Copy link

github-actions bot commented Mar 9, 2026

Claude finished @punkbit's task in 1m 16s —— View job


Code Review

  • Gather context
  • Read changed files
  • Check conventions and guidelines
  • Provide review feedback

✅ This is a clean, minimal PR that correctly exposes DateTimeRangePicker, DateTimeRangePickerProps, and DateRangePickerProps to the public API. No blocking issues.

A couple of minor observations:

💡 Suggestions (non-blocking)

  • DatePickerProps (for the existing DatePicker component) is also not exported in src/index.ts, while the component itself is. This is a pre-existing gap, not introduced here, but since you're already tidying up the Date Picker exports it could be worth adding for consistency: export type { DatePickerProps } from './components/DatePicker/DatePicker.types';

  • OpenDirection is used in DateTimeRangePickerProps.openDirection but is a private local type in DateTimeRangePicker.tsx. This is fine since TypeScript inlines the 'left' | 'right' union directly — consumers don't need to import OpenDirection separately. Just worth noting for future reference.

📦 Changeset note

The changeset bot shows "No Changeset found" but this is expected — this PR modifies the existing .changeset/wild-pillows-agree.md from the base branch (#882) rather than creating a new one. The changeset is properly marked as minor and includes usage examples. Looks good!

@github-actions
Copy link

github-actions bot commented Mar 9, 2026

Claude finished @punkbit's task in 59s —— View job


Code Review

  • Gather context
  • Read changed files
  • Check conventions and guidelines
  • Provide review feedback

✅ Clean, minimal PR — all exports are correct and the types exist in the referenced files.

💡 Suggestions (non-blocking)

  • src/index.ts ordering: The file header comment says "Please keep the types next to the component", but the new type exports are grouped at the bottom of the Date Picker section rather than directly beneath each component. Other sections (e.g. Alert, Badge) follow the paired pattern. Consider reordering:

    // Date Picker
    export { DatePicker } from './components/DatePicker';
    export type { DatePickerProps } from './components/DatePicker';
    export { DateRangePicker } from './components/DatePicker/DateRangePicker';
    export type { DateRangePickerProps } from './components/DatePicker/DateRangePicker';
    export { DateTimeRangePicker } from './components/DatePicker/DateTimeRangePicker';
    export type { DateTimeRangePickerProps } from './components/DatePicker/DateTimeRangePicker';
    export { getPredefinedMonthsForDateRangePicker } from './components/DatePicker/utils';
    export type { DateRange } from './components/DatePicker/utils';

    Fix this →

This is non-blocking — everything exported is correct and the types properly match the component files. Nice work adding DatePickerProps while you were at it! 🙌

@github-actions
Copy link

github-actions bot commented Mar 9, 2026

Claude finished @punkbit's task in 43s —— View job


Code Review

  • Gather context
  • Read changed files
  • Check conventions and guidelines
  • Provide review feedback

✅ All exports are correct and types exist at the referenced paths. No blocking issues.

💡 Suggestion (non-blocking)

The previous review noted that the file header says "keep types next to the component", and the current ordering groups the export type lines after all the export lines rather than pairing them. The other sections (e.g. Dialog, FileTabs) follow the paired pattern. Consider reordering the Date Picker section in src/index.ts (lines 107–115) like so:

// Date Picker
export { DatePicker } from './components/DatePicker';
export type { DatePickerProps } from './components/DatePicker';
export { DateRangePicker } from './components/DatePicker/DateRangePicker';
export type { DateRangePickerProps } from './components/DatePicker/DateRangePicker';
export { DateTimeRangePicker } from './components/DatePicker/DateTimeRangePicker';
export type { DateTimeRangePickerProps } from './components/DatePicker/DateTimeRangePicker';
export { getPredefinedMonthsForDateRangePicker } from './components/DatePicker/utils';
export type { DateRange } from './components/DatePicker/utils';

This is purely cosmetic and non-blocking — the exports themselves are all correct. Nice, clean PR! 🙌

Base automatically changed from bucky-rename-datetimepicker to main March 9, 2026 14:16
@github-actions
Copy link

github-actions bot commented Mar 9, 2026

Claude finished @punkbit's task in 1m 7s —— View job


Code Review

  • Gather context
  • Read changed files
  • Check conventions and guidelines
  • Provide review feedback

✅ All exports resolve correctly — DatePickerProps, DateRangePickerProps, and DateTimeRangePickerProps are all defined and re-exported through src/components/DatePicker/index.ts. No missing types, no broken paths.

💡 Suggestion (non-blocking)

The file header on src/index.ts says "Please keep the types next to the component", but the Date Picker section still groups all types after all component exports. Multiple previous reviews have flagged this. Since this PR touches the section anyway, consider fixing the ordering:

// Date Picker
export { DatePicker } from './components/DatePicker';
export type { DatePickerProps } from './components/DatePicker';
export { DateRangePicker } from './components/DatePicker/DateRangePicker';
export type { DateRangePickerProps } from './components/DatePicker/DateRangePicker';
export { DateTimeRangePicker } from './components/DatePicker/DateTimeRangePicker';
export type { DateTimeRangePickerProps } from './components/DatePicker/DateTimeRangePicker';
export { getPredefinedMonthsForDateRangePicker } from './components/DatePicker/utils';
export type { DateRange } from './components/DatePicker/utils';

Fix this →

📝 Changeset note

The changeset is missing a trailing newline at the end of .changeset/wild-pillows-agree.md (minor).

Nice, clean PR — everything exported is correct! 🙌

@github-actions
Copy link

github-actions bot commented Mar 9, 2026

Claude finished @punkbit's task in 1m 0s —— View job


Code Review

  • Gather context
  • Read changed files
  • Check conventions and guidelines
  • Provide review feedback

✅ Looks great! No issues found — the previous review suggestions have all been addressed.

What's in this PR:

  • DatePicker, DateRangePicker, DateTimeRangePicker components are now all paired with their corresponding export type lines in src/index.ts
  • The ordering follows the file header convention ("keep types next to the component") — each type export sits directly beneath its component export
  • All type definitions resolve correctly (DatePickerProps, DateRangePickerProps, DateTimeRangePickerProps all exist at the referenced paths)
  • The changeset is well-written with usage examples

One cosmetic note (non-blocking): .changeset/wild-pillows-agree.md is missing a trailing newline at the end of the file (No newline at end of file). Not a blocker, but easy to fix.

Nice, clean PR — everything looks solid! 🙌

@workflow-authentication-public
Copy link
Contributor

📚 Storybook Preview Deployed

✅ Preview URL: https://click-ejtays437-clickhouse.vercel.app

Built from commit: c9a3377e6fd1dda129d26ff48adb6d36a090f425

@punkbit punkbit merged commit c7e903c into main Mar 9, 2026
8 checks passed
@punkbit punkbit deleted the chore/expose-datetimerangepicker-comp-types-to-main-public-api branch March 9, 2026 14:33
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.

4 participants