✨(Modal, Calendar): add variants and extract calendar#381
Open
PanchoutNathan wants to merge 7 commits intomainfrom
Open
✨(Modal, Calendar): add variants and extract calendar#381PanchoutNathan wants to merge 7 commits intomainfrom
PanchoutNathan wants to merge 7 commits intomainfrom
Conversation
Refactor Modal to support two variants: default and tab. Extract layout components into separate files: - ModalDefaultLayout: title, subtitle, icon, compact mode - ModalTabLayout: sidebar navigation with tab selection - ModalFooter: left/right split actions - ChevronIcons and CloseIcon: SVG icon components Update helper modals to use new rightActions prop.
Add SCSS styles for default and tab modal variants: - Compact title mode with smaller font size - Subtitle support and title icon alignment - Tab sidebar with active/hover states - Responsive footer with left/right split Add component tokens for new variant properties. Add tests covering tab navigation and mobile view. Add stories for subtitle, title icon, compact mode and sticky footer.
Move Calendar, CalendarCell and CalendarGrid from Forms/DatePicker into a new top-level Calendar component directory. Export Calendar and CalendarRange from the library. Add dedicated SCSS styles, tokens, tests and stories. Update DatePicker imports to use new Calendar path.
Reduce form input font-size from md to sm across Input, Select, TextArea, LabelledBox and DatePicker. Update Button border-radius from 8px to 4px. Remove calendar-related tokens from DatePicker (now in Calendar component tokens). Update form SCSS styles accordingly.
Bump react-aria packages to latest versions: - @react-aria/calendar 3.8.0 → 3.9.5 - @react-aria/datepicker 3.14.2 → 3.16.1 - @react-aria/i18n 3.12.8 → 3.12.16 - react-aria 3.39.0 → 3.47.0 - react-aria-components 1.8.0 → 1.16.0 Add calendar-specific locale keys for reset, cancel and ok buttons in en-US and fr-FR.
Regenerate CSS, JS, SCSS and TS token files to reflect new Calendar component tokens, updated Modal tokens and form font-size changes.
NathanVss
approved these changes
Mar 27, 2026
Collaborator
There was a problem hiding this comment.
Let's stick to one file per icon to optimize imports
Collaborator
| closeOnClickOutside?: boolean; | ||
| closeOnEsc?: boolean; | ||
| preventClose?: boolean; | ||
| dimensions?: ModalDimensions; |
Collaborator
There was a problem hiding this comment.
what this new addition solves as a problem?
Not sure we want to introduce custom sized modals, as the DS should give strict rules, I fear that the apps will have yolo modals with all kind of sizes
Collaborator
Collaborator
There was a problem hiding this comment.
Make sure to update the main story to include this variants
https://suitenumerique.github.io/cunningham/storybook/?path=/docs/components-modal--docs
| // Dimensions stories | ||
| // ===================== | ||
|
|
||
| export const FixedHeight: Story = { |
Collaborator
Collaborator
There was a problem hiding this comment.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.





Summary
layout components, new styles, tokens, tests and stories
DatePicker, with dedicated styles, tokens, tests and stories