Skip to content

feat(calendar): add day template - #17846

Open
teodosiah wants to merge 12 commits into
masterfrom
thristodorova/feat-17822-calendar-day-template
Open

teodosiah wants to merge 12 commits into
masterfrom
thristodorova/feat-17822-calendar-day-template

Conversation

@teodosiah

@teodosiah teodosiah commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

Closes #17822

IgxCalendar, IgxDatePicker and IgxDateRangePicker Specifications have been updated.

Description

Add the igxCalendarDay directive and the dayTemplate input to customize the content of the calendar day cells. The template receives the date and the day states through IgxCalendarDayTemplateContext, while the cells keep their selection, keyboard navigation, ARIA and styling. The date picker and date range picker pass the template to their calendar.

Motivation / Context

Type of Change (check all that apply):

  • Bug fix
  • New functionality
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Refactoring (no functional changes)
  • Documentation
  • Demos
  • CI/CD
  • Tests
  • Changelog
  • Skills/Agents

Component(s) / Area(s) Affected:

How Has This Been Tested?

  • Unit tests
  • Manual testing
  • Automated e2e tests

Test Configuration:

  • Angular version:
  • Browser(s):
  • OS:

Screenshots / Recordings

Checklist:

  • All relevant labels have been applied to this PR
  • This PR includes unit tests covering all the new code (test guidelines)
  • This PR includes API docs for newly added methods/properties (api docs guidelines)
  • This PR includes feature/README.MD updates for the feature docs
  • This PR includes general feature table updates in the root README.MD
  • This PR includes CHANGELOG.MD updates for newly added functionality
  • This PR contains breaking changes
  • This PR includes ng update migrations for the breaking changes (migrations guidelines)
  • This PR includes behavioral changes and the feature specification has been updated with them
  • Accessibility (ARIA, keyboard navigation, focus management) has been verified

Add the igxCalendarDay directive and the dayTemplate input to customize
the content of the calendar day cells. The template receives the date
and the day states through IgxCalendarDayTemplateContext, while the
cells keep their selection, keyboard navigation, ARIA and styling.
The date picker and date range picker pass the template to their
calendar.

Closes #17822

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 23, 2026 11:45

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Template context values need correction, and both picker import collections must expose the new directive.

3 open issues
What changed in this PR

Adds customizable calendar day content for #17822, with typed date and state context and integration into both date pickers.

Changes:

  • Introduces igxCalendarDay and dayTemplate while retaining existing cell interaction and styling.
  • Adds calendar behavior tests and picker integration tests.
  • Documents the API and adds event-indicator and pricing samples.
File Description
src/​app/​calendar/​calendar.sample.ts Adds template directive imports and sample data helpers.
src/​app/​calendar/​calendar.sample.scss Styles event indicators and prices.
src/​app/​calendar/​calendar.sample.html Demonstrates calendar and range-picker templates.
skills/​igniteui-angular-components/​references/​form-controls.md Documents template usage and constraints.
projects/​igniteui-angular/​date-picker/​src/​date-range-picker/​date-range-picker.component.ts Forwards projected day templates to the calendar.
projects/​igniteui-angular/​date-picker/​src/​date-range-picker/​date-range-picker.component.spec.ts Tests range-picker template rendering.
projects/​igniteui-angular/​date-picker/​src/​date-picker/​date-picker.component.ts Forwards projected day templates to the calendar.
projects/​igniteui-angular/​date-picker/​src/​date-picker/​date-picker.component.spec.ts Tests date-picker template rendering.
projects/​igniteui-angular/​calendar/​src/​calendar/​public_api.ts Adds the directive to the calendar import collection.
projects/​igniteui-angular/​calendar/​src/​calendar/​days-view/​days-view.component.ts Accepts a typed day template.
projects/​igniteui-angular/​calendar/​src/​calendar/​days-view/​days-view.component.html Renders custom content for visible days.
projects/​igniteui-angular/​calendar/​src/​calendar/​days-view/​day-item.component.ts Builds the date and state context.
projects/​igniteui-angular/​calendar/​src/​calendar/​calendar.directives.ts Defines the directive and typed context.
projects/​igniteui-angular/​calendar/​src/​calendar/​calendar.component.ts Resolves input and projected templates.
projects/​igniteui-angular/​calendar/​src/​calendar/​calendar.component.spec.ts Tests context, interaction, precedence, and multiple views.
projects/​igniteui-angular/​calendar/​src/​calendar/​calendar.component.html Passes the template to each days view.
projects/​igniteui-angular/​calendar/​README.md Documents the API, context, and accessibility constraints.
CHANGELOG.md Announces day-template support.

Review effort: Balanced

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Projected day templates can become stale while a picker is open, and meaningful custom day content is unavailable to screen-reader users.

3 open issues

Review effort: Balanced

teodosiah and others added 3 commits October 28, 2026 13:52
Announce the day template text as the day cell description through
aria-describedby, and pass projected igxCalendarDay template changes
to the calendar of an open date picker or date range picker.
Reuse the day template context without extra allocations.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@mddragnev mddragnev left a comment

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.

Could you also update the Specification of the calendar,date/date-range pickers?

teodosiah and others added 2 commits October 29, 2026 11:26
Rename the projected day template query to contentDayTemplate, drop the
unneeded forwardRef, markForCheck, standalone flag and internal doc tags,
and keep the same date reference in the day template context until the
day changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@teodosiah
teodosiah requested a review from mddragnev October 29, 2026 11:39
@viktorkombov viktorkombov added 💥 status: in-test PRs currently being tested and removed ❌ status: awaiting-test PRs awaiting manual verification labels Oct 29, 2026
@viktorkombov viktorkombov added awaiting author When the reviewer/verifier has some confusions about the scenario/behavior and wait author's action and removed 💥 status: in-test PRs currently being tested labels Oct 29, 2026
Do not hide the templated day content from assistive technologies, so
hidden parts of the template stay out of the day cell description.
Document the IgxCalendarDayTemplateDirective import in the README and
make the day template date reference test cover a reused day cell.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@teodosiah teodosiah added ❌ status: awaiting-test PRs awaiting manual verification and removed awaiting author When the reviewer/verifier has some confusions about the scenario/behavior and wait author's action labels Oct 30, 2026
@viktorkombov viktorkombov added ✅ status: verified Applies to PRs that have passed manual verification and removed ❌ status: awaiting-test PRs awaiting manual verification labels Oct 30, 2026
@ChronosSF
ChronosSF enabled auto-merge (squash) October 30, 2026 17:28

This branch has not been deployed

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

Labels

📆 calendar ✅ status: verified Applies to PRs that have passed manual verification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Calendar] Support custom day cell templates

5 participants