Skip to content

refactor: inner state of Range/DateField components#270

Open
ValeraS wants to merge 5 commits intomainfrom
refactor/Range_DateField
Open

refactor: inner state of Range/DateField components#270
ValeraS wants to merge 5 commits intomainfrom
refactor/Range_DateField

Conversation

@ValeraS
Copy link
Collaborator

@ValeraS ValeraS commented Feb 19, 2026

No description provided.

@ValeraS ValeraS changed the title refactor/Range_DateField refactor: Range/DateField Feb 19, 2026
@github-actions
Copy link

github-actions bot commented Feb 19, 2026

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 61.69% 1559 / 2527
🔵 Statements 61.87% 1592 / 2573
🔵 Functions 63.12% 303 / 480
🔵 Branches 56.2% 1259 / 2240
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
src/components/DateField/DateField.tsx 100% 85.71% 100% 100%
src/components/DateField/index.ts 100% 100% 100% 100%
src/components/DateField/types.ts 100% 100% 100% 100%
src/components/DateField/utils.ts 79.85% 65.36% 100% 79.48% 106-115, 159-162, 227, 247, 255, 257, 275-280, 287-288, 300, 304, 320-326, 362-370, 376-382, 394-395, 404-409, 411-416, 456, 472, 522, 540-544, 559, 567, 583, 605, 683, 693-696, 702, 719, 804-805
src/components/DateField/hooks/useBaseDateFieldState.ts 34.21% 29.62% 55.55% 34.21% 106, 114-119, 124, 132-158, 164, 168, 175
src/components/DateField/hooks/useDateFieldProps.ts 66.97% 67.45% 86.36% 67.14% 61, 104, 109, 126-139, 141-145, 171-197, 209, 216-217, 225, 234, 268, 275-276, 281, 296-298, 304-306, 308-310, 316-318, 324-326, 357-359, 372, 393-394, 397, 415
src/components/DateField/hooks/useDateFieldState.ts 87.32% 82.14% 92.85% 87.14% 66, 112, 119-120, 154-156, 167, 172
src/components/DateField/hooks/useFocusManager.ts 73.01% 53.84% 66.66% 71.66% 55, 64-68, 73, 92-107, 125
src/components/RangeDateField/RangeDateField.tsx 100% 92.3% 100% 100%
src/components/RangeDateField/index.ts 100% 100% 100% 100%
src/components/RangeDatePicker/hooks/useRangeDatePickerState.ts 63.63% 100% 50% 63.63% 30, 49-51
src/components/utils/constants.ts 100% 62.5% 100% 100%
src/components/utils/dates.ts 84.21% 70% 100% 84.21% 31, 34, 46
Generated in workflow #42 for commit 7aa6f74 by the Vitest Coverage Report Action

@gravity-ui-bot
Copy link
Contributor

Preview is ready.

@gravity-ui-bot
Copy link
Contributor

gravity-ui-bot commented Feb 19, 2026

🎭 Tests Report is ready.
🎭 Coverage Report is ready.

@ValeraS ValeraS changed the title refactor: Range/DateField refactor: inner state of Range/DateField components Feb 19, 2026
@ValeraS ValeraS marked this pull request as ready for review February 19, 2026 15:04
- move focus management to separate hook
- move onInput logic to useDateFieldProps
- move useRangeDateFieldState to DateField hooks
- calculate connections between sections in useFocusManager
- generate input value and section positions in useDateFieldProps
@ValeraS ValeraS force-pushed the refactor/Range_DateField branch from f38644b to 7aa6f74 Compare February 19, 2026 15:13
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