Skip to content

Scheduler: refactor workspaces module (TS): part 3#33904

Merged
sjbur merged 11 commits into
DevExpress:26_1from
sjbur:issue-4460_26_1_v3
Jun 9, 2026
Merged

Scheduler: refactor workspaces module (TS): part 3#33904
sjbur merged 11 commits into
DevExpress:26_1from
sjbur:issue-4460_26_1_v3

Conversation

@sjbur

@sjbur sjbur commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@sjbur sjbur self-assigned this Jun 8, 2026
@sjbur sjbur added the 26_1 label Jun 8, 2026
@sjbur sjbur marked this pull request as ready for review June 8, 2026 13:33
@sjbur sjbur requested a review from a team as a code owner June 8, 2026 13:33
Copilot AI review requested due to automatic review settings June 8, 2026 13:33

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.

Pull request overview

Refactors Scheduler workspace grouping strategies toward stronger TypeScript typing and adds all-day awareness to horizontal group-bounds calculations, continuing the ongoing workspaces module refactor.

Changes:

  • Extends workspace group-bounds APIs to accept an optional allDay flag and threads it through resizing logic.
  • Migrates horizontal/vertical grouped strategies to use a typed workspace reference and introduces GroupBoundsOffset typing.
  • Reuses shared CellPositionData in cell selection controller (removing a local duplicate type).

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
packages/devextreme/js/__internal/scheduler/workspaces/m_work_space.ts Adds optional allDay plumbing for group bounds and forwards it into the horizontal strategy.
packages/devextreme/js/__internal/scheduler/workspaces/m_work_space_grouped_strategy_vertical.ts Refactors vertical grouped strategy to use a typed workspace and adds return/param typings.
packages/devextreme/js/__internal/scheduler/workspaces/m_work_space_grouped_strategy_horizontal.ts Refactors horizontal grouped strategy typing, adds safer bounds computation paths, and threads allDay into coordinate->cell index mapping.
packages/devextreme/js/__internal/scheduler/workspaces/cells_selection_controller.ts Replaces local GridPosition with shared CellPositionData.
packages/devextreme/js/__internal/scheduler/types.ts Introduces GroupBoundsOffset interface.
packages/devextreme/js/__internal/scheduler/m_subscribes.ts Passes allDay into workspace getGroupBounds for resizable area calculation.

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.

Pull request overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated no new comments.


if (!groupByDay) {
return {
rowIndex: cellCoordinates.rowIndex,
columnIndex: cellCoordinates.columnIndex + groupIndex * this._workSpace.getCellCount(),
// @ts-expect-error

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Here and all new @ts-expect-error lines appeared because of strict typing. Many methods from workspace are private. In the task of replacing workspace with proxy config object those lines will be removed

Copilot AI review requested due to automatic review settings June 9, 2026 11:59

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.

Pull request overview

Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.

Comment on lines +1372 to 1374
getTimePanelWidth(): number {
return this.$timePanel && getBoundingRect(this.$timePanel.get(0)).width;
}
Comment on lines +101 to +103
const extraOffset = cellWidth / 2;
const startLeft = startCell?.length ? (startCell.offset()?.left ?? 0) : undefined;
const endLeft = endCell?.length ? (endCell.offset()?.left ?? 0) : undefined;
@sjbur sjbur merged commit 0116fdb into DevExpress:26_1 Jun 9, 2026
103 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants