@lifesg/react-design-system 4.0.0-alpha.12 → 4.0.0-alpha.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/breadcrumb/breadcrumb.js +1 -1
- package/breadcrumb/breadcrumb.js.map +1 -1
- package/breadcrumb/breadcrumb.styles.d.ts +0 -8
- package/breadcrumb/breadcrumb.styles.js +1 -1
- package/breadcrumb/breadcrumb.styles.js.map +1 -1
- package/breadcrumb/breadcrumb.styles_1blzn8n.css +7 -0
- package/breadcrumb/types.d.ts +2 -13
- package/cjs/breadcrumb/breadcrumb.js +1 -1
- package/cjs/breadcrumb/breadcrumb.js.map +1 -1
- package/cjs/breadcrumb/breadcrumb.styles.js +1 -1
- package/cjs/breadcrumb/breadcrumb.styles.js.map +1 -1
- package/cjs/breadcrumb/breadcrumb.styles_1blzn8n.css +7 -0
- package/cjs/drawer/drawer.js +1 -1
- package/cjs/drawer/drawer.js.map +1 -1
- package/cjs/drawer/drawer.styles.js +1 -1
- package/cjs/drawer/drawer.styles.js.map +1 -1
- package/{drawer/drawer.styles_94hx3y.css → cjs/drawer/drawer.styles_a4bwe0.css} +6 -3
- package/cjs/external/dompurify/dist/purify.es.js +4 -2
- package/cjs/external/dompurify/dist/purify.es.js.map +1 -1
- package/cjs/file-upload/file-list/file-list.js +1 -1
- package/cjs/file-upload/file-list/file-list.js.map +1 -1
- package/cjs/file-upload/file-list/file-list.styles.js +1 -1
- package/cjs/file-upload/file-list/file-list.styles.js.map +1 -1
- package/cjs/file-upload/file-list/file-list.styles_1xbypnh.css +2 -0
- package/cjs/file-upload/file-list-item/file-item-actions.js +2 -0
- package/cjs/file-upload/file-list-item/file-item-actions.js.map +1 -0
- package/cjs/file-upload/file-list-item/file-item-actions.styles.js +2 -0
- package/cjs/file-upload/file-list-item/file-item-actions.styles.js.map +1 -0
- package/cjs/file-upload/file-list-item/file-item-actions.styles_1quulgy.css +8 -0
- package/cjs/file-upload/file-list-item/file-item-details.js +2 -0
- package/cjs/file-upload/file-list-item/file-item-details.js.map +1 -0
- package/cjs/file-upload/file-list-item/file-item-details.styles.js +2 -0
- package/cjs/file-upload/file-list-item/file-item-details.styles.js.map +1 -0
- package/cjs/file-upload/file-list-item/file-item-details.styles_1ce9akx.css +7 -0
- package/cjs/file-upload/file-list-item/file-list-item.js +1 -1
- package/cjs/file-upload/file-list-item/file-list-item.js.map +1 -1
- package/cjs/file-upload/file-list-item/file-list-item.styles.js +1 -1
- package/cjs/file-upload/file-list-item/file-list-item.styles.js.map +1 -1
- package/cjs/file-upload/file-list-item/file-list-item.styles_x3a500.css +10 -0
- package/cjs/file-upload/file-list-item/use-truncated-name.js +2 -0
- package/cjs/file-upload/file-list-item/use-truncated-name.js.map +1 -0
- package/cjs/local-nav/local-nav-dropdown/local-nav-dropdown.js +1 -1
- package/cjs/local-nav/local-nav-dropdown/local-nav-dropdown.js.map +1 -1
- package/cjs/local-nav/local-nav-dropdown/local-nav-dropdown.styles.js +1 -1
- package/cjs/local-nav/local-nav-dropdown/local-nav-dropdown.styles.js.map +1 -1
- package/{local-nav/local-nav-dropdown/local-nav-dropdown.styles_uhd4xl.css → cjs/local-nav/local-nav-dropdown/local-nav-dropdown.styles_kpel1m.css} +9 -6
- package/cjs/local-nav/local-nav-menu/local-nav-menu.js +1 -1
- package/cjs/local-nav/local-nav-menu/local-nav-menu.js.map +1 -1
- package/cjs/local-nav/local-nav-menu/local-nav-menu.styles.js +1 -1
- package/cjs/local-nav/local-nav-menu/local-nav-menu.styles.js.map +1 -1
- package/cjs/local-nav/local-nav-menu/local-nav-menu.styles_67fcyc.css +8 -0
- package/cjs/menu/menu-content.js +1 -1
- package/cjs/menu/menu-content.js.map +1 -1
- package/cjs/menu/menu-content.styles.js +1 -1
- package/cjs/menu/menu-content.styles.js.map +1 -1
- package/cjs/menu/menu-content.styles_1r8oxtk.css +5 -0
- package/cjs/menu/menu-item.styles.js +1 -1
- package/cjs/menu/menu-item.styles.js.map +1 -1
- package/cjs/menu/{menu-item.styles_liyed8.css → menu-item.styles_eut2j9.css} +1 -1
- package/cjs/menu/menu-link.styles.js +1 -1
- package/cjs/menu/menu-link.styles.js.map +1 -1
- package/cjs/menu/menu-link.styles_rng7n7.css +2 -0
- package/cjs/menu/menu-section.js +1 -1
- package/cjs/menu/menu-section.js.map +1 -1
- package/cjs/menu/menu-section.styles.js +1 -1
- package/cjs/menu/menu-section.styles.js.map +1 -1
- package/cjs/menu/menu-section.styles_1n0ppxl.css +5 -0
- package/cjs/modal-v2/slots/slot-styles.js +1 -1
- package/cjs/modal-v2/slots/slot-styles.js.map +1 -1
- package/cjs/modal-v2/slots/{slot-styles_ayb9il.css → slot-styles_ygu6zc.css} +1 -1
- package/cjs/navbar/navbar-items.js +1 -1
- package/cjs/navbar/navbar-items.js.map +1 -1
- package/cjs/notification-banner/notification-banner-hoc.js +1 -1
- package/cjs/notification-banner/notification-banner-hoc.js.map +1 -1
- package/cjs/pagination/pagination.js +1 -1
- package/cjs/pagination/pagination.js.map +1 -1
- package/cjs/shared/dropdown-list/dropdown-label.js +1 -1
- package/cjs/shared/dropdown-list/dropdown-label.js.map +1 -1
- package/cjs/shared/fade-wrapper/fade-wrapper.js +1 -1
- package/cjs/shared/fade-wrapper/fade-wrapper.js.map +1 -1
- package/cjs/theme/tokens/colour.js +1 -1
- package/cjs/theme/tokens/colour.js.map +1 -1
- package/cjs/theme/tokens/radius.js +1 -1
- package/cjs/theme/tokens/radius.js.map +1 -1
- package/codemods/run-codemod.js +8 -2
- package/codemods/run-codemod.js.map +1 -1
- package/codemods/run-codemod.ts +13 -4
- package/drawer/drawer.d.ts +1 -1
- package/drawer/drawer.js +1 -1
- package/drawer/drawer.js.map +1 -1
- package/drawer/drawer.styles.d.ts +3 -0
- package/drawer/drawer.styles.js +1 -1
- package/drawer/drawer.styles.js.map +1 -1
- package/{cjs/drawer/drawer.styles_94hx3y.css → drawer/drawer.styles_a4bwe0.css} +6 -3
- package/drawer/types.d.ts +7 -0
- package/external/dompurify/dist/purify.es.js +4 -2
- package/external/dompurify/dist/purify.es.js.map +1 -1
- package/file-upload/file-list/file-list.js +1 -1
- package/file-upload/file-list/file-list.js.map +1 -1
- package/file-upload/file-list/file-list.styles.d.ts +0 -1
- package/file-upload/file-list/file-list.styles.js +1 -1
- package/file-upload/file-list/file-list.styles.js.map +1 -1
- package/file-upload/file-list/file-list.styles_1xbypnh.css +2 -0
- package/file-upload/file-list-item/file-item-actions.d.ts +30 -0
- package/file-upload/file-list-item/file-item-actions.js +2 -0
- package/file-upload/file-list-item/file-item-actions.js.map +1 -0
- package/file-upload/file-list-item/file-item-actions.styles.d.ts +6 -0
- package/file-upload/file-list-item/file-item-actions.styles.js +2 -0
- package/file-upload/file-list-item/file-item-actions.styles.js.map +1 -0
- package/file-upload/file-list-item/file-item-actions.styles_1quulgy.css +8 -0
- package/file-upload/file-list-item/file-item-details.d.ts +15 -0
- package/file-upload/file-list-item/file-item-details.js +2 -0
- package/file-upload/file-list-item/file-item-details.js.map +1 -0
- package/file-upload/file-list-item/file-item-details.styles.d.ts +7 -0
- package/file-upload/file-list-item/file-item-details.styles.js +2 -0
- package/file-upload/file-list-item/file-item-details.styles.js.map +1 -0
- package/file-upload/file-list-item/file-item-details.styles_1ce9akx.css +7 -0
- package/file-upload/file-list-item/file-list-item.d.ts +1 -7
- package/file-upload/file-list-item/file-list-item.js +1 -1
- package/file-upload/file-list-item/file-list-item.js.map +1 -1
- package/file-upload/file-list-item/file-list-item.styles.d.ts +6 -13
- package/file-upload/file-list-item/file-list-item.styles.js +1 -1
- package/file-upload/file-list-item/file-list-item.styles.js.map +1 -1
- package/file-upload/file-list-item/file-list-item.styles_x3a500.css +10 -0
- package/file-upload/file-list-item/types.d.ts +10 -3
- package/file-upload/file-list-item/use-truncated-name.d.ts +1 -0
- package/file-upload/file-list-item/use-truncated-name.js +2 -0
- package/file-upload/file-list-item/use-truncated-name.js.map +1 -0
- package/input-group/types.d.ts +4 -1
- package/input-select/types.d.ts +1 -0
- package/local-nav/local-nav-dropdown/local-nav-dropdown.js +1 -1
- package/local-nav/local-nav-dropdown/local-nav-dropdown.js.map +1 -1
- package/local-nav/local-nav-dropdown/local-nav-dropdown.styles.d.ts +3 -0
- package/local-nav/local-nav-dropdown/local-nav-dropdown.styles.js +1 -1
- package/local-nav/local-nav-dropdown/local-nav-dropdown.styles.js.map +1 -1
- package/{cjs/local-nav/local-nav-dropdown/local-nav-dropdown.styles_uhd4xl.css → local-nav/local-nav-dropdown/local-nav-dropdown.styles_kpel1m.css} +9 -6
- package/local-nav/local-nav-menu/local-nav-menu.js +1 -1
- package/local-nav/local-nav-menu/local-nav-menu.js.map +1 -1
- package/local-nav/local-nav-menu/local-nav-menu.styles.d.ts +3 -0
- package/local-nav/local-nav-menu/local-nav-menu.styles.js +1 -1
- package/local-nav/local-nav-menu/local-nav-menu.styles.js.map +1 -1
- package/local-nav/local-nav-menu/local-nav-menu.styles_67fcyc.css +8 -0
- package/local-nav/types.d.ts +17 -0
- package/masked-input/types.d.ts +1 -2
- package/menu/menu-content.js +1 -1
- package/menu/menu-content.js.map +1 -1
- package/menu/menu-content.styles.d.ts +1 -0
- package/menu/menu-content.styles.js +1 -1
- package/menu/menu-content.styles.js.map +1 -1
- package/menu/menu-content.styles_1r8oxtk.css +5 -0
- package/menu/menu-item.styles.js +1 -1
- package/menu/menu-item.styles.js.map +1 -1
- package/menu/{menu-item.styles_liyed8.css → menu-item.styles_eut2j9.css} +1 -1
- package/menu/menu-link.styles.js +1 -1
- package/menu/menu-link.styles.js.map +1 -1
- package/menu/menu-link.styles_rng7n7.css +2 -0
- package/menu/menu-section.d.ts +1 -1
- package/menu/menu-section.js +1 -1
- package/menu/menu-section.js.map +1 -1
- package/menu/menu-section.styles.d.ts +7 -0
- package/menu/menu-section.styles.js +1 -1
- package/menu/menu-section.styles.js.map +1 -1
- package/menu/menu-section.styles_1n0ppxl.css +5 -0
- package/menu/menu.d.ts +1 -1
- package/menu/types.d.ts +10 -2
- package/modal-v2/slots/slot-styles.js +1 -1
- package/modal-v2/slots/slot-styles.js.map +1 -1
- package/modal-v2/slots/{slot-styles_ayb9il.css → slot-styles_ygu6zc.css} +1 -1
- package/navbar/navbar-items.js +1 -1
- package/navbar/navbar-items.js.map +1 -1
- package/navbar/types.d.ts +9 -0
- package/notification-banner/notification-banner-hoc.js +1 -1
- package/notification-banner/notification-banner-hoc.js.map +1 -1
- package/package.json +3 -4
- package/pagination/pagination.js +1 -1
- package/pagination/pagination.js.map +1 -1
- package/pagination/types.d.ts +8 -1
- package/scripts/cli.js +18 -0
- package/select-histogram/types.d.ts +1 -0
- package/shared/dropdown-list/dropdown-label.d.ts +2 -2
- package/shared/dropdown-list/dropdown-label.js +1 -1
- package/shared/dropdown-list/dropdown-label.js.map +1 -1
- package/shared/dropdown-list/types.d.ts +6 -2
- package/shared/fade-wrapper/fade-wrapper.js +1 -1
- package/shared/fade-wrapper/fade-wrapper.js.map +1 -1
- package/shared/fade-wrapper/types.d.ts +1 -0
- package/shared/styles/index.d.ts +5 -0
- package/skills/fds-build/SKILL.md +167 -0
- package/skills/fds-build/catalogue.md +181 -0
- package/skills/fds-build/evals/evals.json +519 -0
- package/skills/fds-build/resources/components/accordion.md +128 -0
- package/skills/fds-build/resources/components/alert.md +54 -0
- package/skills/fds-build/resources/components/animation.md +18 -0
- package/skills/fds-build/resources/components/avatar.md +10 -0
- package/skills/fds-build/resources/components/badge.md +18 -0
- package/skills/fds-build/resources/components/box-container.md +61 -0
- package/skills/fds-build/resources/components/breadcrumb.md +60 -0
- package/skills/fds-build/resources/components/button.md +74 -0
- package/skills/fds-build/resources/components/calendar.md +113 -0
- package/skills/fds-build/resources/components/card.md +43 -0
- package/skills/fds-build/resources/components/checkbox.md +53 -0
- package/skills/fds-build/resources/components/countdown-timer.md +20 -0
- package/skills/fds-build/resources/components/data-table.md +142 -0
- package/skills/fds-build/resources/components/date-navigator.md +25 -0
- package/skills/fds-build/resources/components/divider.md +23 -0
- package/skills/fds-build/resources/components/drawer.md +78 -0
- package/skills/fds-build/resources/components/error-display.md +137 -0
- package/skills/fds-build/resources/components/feedback-rating.md +61 -0
- package/skills/fds-build/resources/components/file-download.md +54 -0
- package/skills/fds-build/resources/components/file-upload.md +105 -0
- package/skills/fds-build/resources/components/filter.md +228 -0
- package/skills/fds-build/resources/components/footer.md +94 -0
- package/skills/fds-build/resources/components/form-date-input.md +85 -0
- package/skills/fds-build/resources/components/form-date-range-input.md +146 -0
- package/skills/fds-build/resources/components/form-e-signature.md +55 -0
- package/skills/fds-build/resources/components/form-input.md +65 -0
- package/skills/fds-build/resources/components/form-masked-input.md +69 -0
- package/skills/fds-build/resources/components/form-multi-select.md +100 -0
- package/skills/fds-build/resources/components/form-nested-multi-select.md +159 -0
- package/skills/fds-build/resources/components/form-nested-select.md +151 -0
- package/skills/fds-build/resources/components/form-otp-verification.md +175 -0
- package/skills/fds-build/resources/components/form-phone-number-input.md +87 -0
- package/skills/fds-build/resources/components/form-predictive-text-input.md +108 -0
- package/skills/fds-build/resources/components/form-select.md +103 -0
- package/skills/fds-build/resources/components/form-slider.md +116 -0
- package/skills/fds-build/resources/components/form-textarea.md +116 -0
- package/skills/fds-build/resources/components/form-time-range-picker.md +98 -0
- package/skills/fds-build/resources/components/form-timepicker.md +77 -0
- package/skills/fds-build/resources/components/form-unit-number-input.md +138 -0
- package/skills/fds-build/resources/components/fullscreen-image-carousel.md +159 -0
- package/skills/fds-build/resources/components/histogram-slider.md +41 -0
- package/skills/fds-build/resources/components/icon.md +167 -0
- package/skills/fds-build/resources/components/image-button.md +12 -0
- package/skills/fds-build/resources/components/input.md +51 -0
- package/skills/fds-build/resources/components/language-switcher.md +15 -0
- package/skills/fds-build/resources/components/layout.md +156 -0
- package/skills/fds-build/resources/components/link-list.md +120 -0
- package/skills/fds-build/resources/components/local-nav.md +119 -0
- package/skills/fds-build/resources/components/masthead.md +14 -0
- package/skills/fds-build/resources/components/menu.md +109 -0
- package/skills/fds-build/resources/components/modal.md +150 -0
- package/skills/fds-build/resources/components/navbar.md +270 -0
- package/skills/fds-build/resources/components/notification-banner.md +106 -0
- package/skills/fds-build/resources/components/pagination.md +104 -0
- package/skills/fds-build/resources/components/pill.md +55 -0
- package/skills/fds-build/resources/components/popover.md +80 -0
- package/skills/fds-build/resources/components/progress-indicator.md +47 -0
- package/skills/fds-build/resources/components/radio-button.md +66 -0
- package/skills/fds-build/resources/components/schedule.md +78 -0
- package/skills/fds-build/resources/components/sidenav.md +183 -0
- package/skills/fds-build/resources/components/singpass-button.md +14 -0
- package/skills/fds-build/resources/components/smart-app-banner.md +28 -0
- package/skills/fds-build/resources/components/tab.md +107 -0
- package/skills/fds-build/resources/components/table.md +65 -0
- package/skills/fds-build/resources/components/tag.md +68 -0
- package/skills/fds-build/resources/components/text-list.md +44 -0
- package/skills/fds-build/resources/components/time-slot-bar-week.md +66 -0
- package/skills/fds-build/resources/components/time-slot-bar.md +57 -0
- package/skills/fds-build/resources/components/time-slot-week-view.md +70 -0
- package/skills/fds-build/resources/components/timeline.md +69 -0
- package/skills/fds-build/resources/components/timetable.md +123 -0
- package/skills/fds-build/resources/components/toast.md +72 -0
- package/skills/fds-build/resources/components/toggle.md +119 -0
- package/skills/fds-build/resources/components/typography.md +86 -0
- package/skills/fds-build/resources/components/uneditable-section.md +84 -0
- package/skills/fds-build/resources/foundations/layout-composition-patterns.md +53 -0
- package/skills/fds-build/resources/foundations/tokens.md +547 -0
- package/skills/fds-build/resources/patterns/states.md +300 -0
- package/skills/fds-build/resources/setup/setup.md +202 -0
- package/skills/fds-build/resources/templates/form.md +427 -0
- package/skills/fds-build/resources/templates/listing.md +435 -0
- package/theme/styles/a11y-playground.css +52 -40
- package/theme/styles/bookingsg.css +52 -40
- package/theme/styles/careercompass.css +52 -40
- package/theme/styles/ccube.css +52 -40
- package/theme/styles/imda.css +52 -40
- package/theme/styles/lifesg.css +52 -40
- package/theme/styles/mylegacy.css +52 -40
- package/theme/styles/oneservice.css +52 -40
- package/theme/styles/pa.css +28 -22
- package/theme/styles/rbs.css +52 -40
- package/theme/styles/sgw-digital-lobby.css +52 -40
- package/theme/styles/smgs.css +52 -40
- package/theme/styles/spf.css +28 -27
- package/theme/styles/sportsg-orange.css +52 -40
- package/theme/styles/supportgowhere.css +52 -40
- package/theme/styles/tote-board.css +52 -40
- package/theme/styles/vica.css +52 -40
- package/theme/styles/websg.css +52 -40
- package/theme/styles/wise.css +52 -40
- package/theme/styles/wogaa.css +52 -40
- package/theme/tokens/colour.d.ts +6 -0
- package/theme/tokens/colour.js +1 -1
- package/theme/tokens/colour.js.map +1 -1
- package/theme/tokens/radius.d.ts +3 -0
- package/theme/tokens/radius.js +1 -1
- package/theme/tokens/radius.js.map +1 -1
- package/breadcrumb/breadcrumb.styles_1nl4aua.css +0 -18
- package/cjs/breadcrumb/breadcrumb.styles_1nl4aua.css +0 -18
- package/cjs/file-upload/file-item-edit.js +0 -2
- package/cjs/file-upload/file-item-edit.js.map +0 -1
- package/cjs/file-upload/file-item-edit.styles.js +0 -2
- package/cjs/file-upload/file-item-edit.styles.js.map +0 -1
- package/cjs/file-upload/file-item-edit.styles_19bvztn.css +0 -11
- package/cjs/file-upload/file-list/file-list.styles_1w7so98.css +0 -3
- package/cjs/file-upload/file-list-item/file-list-item.styles_kgtfke.css +0 -17
- package/cjs/local-nav/local-nav-menu/local-nav-menu.styles_pq19dh.css +0 -5
- package/cjs/menu/menu-content.styles_p7ijll.css +0 -2
- package/cjs/menu/menu-link.styles_hfxoez.css +0 -2
- package/cjs/menu/menu-section.styles_g7my4d.css +0 -3
- package/file-upload/file-item-edit.d.ts +0 -14
- package/file-upload/file-item-edit.js +0 -2
- package/file-upload/file-item-edit.js.map +0 -1
- package/file-upload/file-item-edit.styles.d.ts +0 -9
- package/file-upload/file-item-edit.styles.js +0 -2
- package/file-upload/file-item-edit.styles.js.map +0 -1
- package/file-upload/file-item-edit.styles_19bvztn.css +0 -11
- package/file-upload/file-list/file-list.styles_1w7so98.css +0 -3
- package/file-upload/file-list-item/file-list-item.styles_kgtfke.css +0 -17
- package/local-nav/local-nav-menu/local-nav-menu.styles_pq19dh.css +0 -5
- package/menu/menu-content.styles_p7ijll.css +0 -2
- package/menu/menu-link.styles_hfxoez.css +0 -2
- package/menu/menu-section.styles_g7my4d.css +0 -3
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
# Flagship Component Catalogue
|
|
2
|
+
|
|
3
|
+
One-liner per component. Read `./resources/components/{key}.md` for full props and usage rules before writing code.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Buttons & Actions
|
|
8
|
+
|
|
9
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
10
|
+
| --------- | -------- | ------------------------------------------------- | ------------------------ | ------------------------------------------------------------------------------------------ | ---------------------------------------------- |
|
|
11
|
+
| `Button` | `button` | CTA, action button, submit button, primary button | `Form`, `Modal`, `Alert` | Button with optional text or icon. Style types: default/secondary/light/link + danger flag | `styleType` (req), `loading`, `danger`, `icon` |
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## Form — Inputs
|
|
16
|
+
|
|
17
|
+
All `Form.*` components import from `@lifesg/react-design-system/form`. `label` is required on every field.
|
|
18
|
+
|
|
19
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
20
|
+
| -------------------------- | ---------------------------- | ------------------------------------------------------------------ | ---------------------- | ---------------------------------------------------- | -------------------------------------------------------------- |
|
|
21
|
+
| `Form.Input` | `form-input` | text field, labeled input, form field, input box | `Alert`, `Button` | Standard labeled text input with error state | `label` (req), `value`, `onChange`, `errorMessage` |
|
|
22
|
+
| `Form.Textarea` | `form-textarea` | multiline, long text, text area, comments box | `Alert`, `Button` | Multi-line text input | `label` (req), `value`, `onChange`, `rows` |
|
|
23
|
+
| `Form.Select` | `form-select` | dropdown, select, single select, picker | `Form.Input`, `Button` | Single-option dropdown | `label` (req), `options`, `selectedOption`, `onSelectOption` |
|
|
24
|
+
| `Form.MultiSelect` | `form-multi-select` | multi-select, multi-choice dropdown, multi-pick | `Form.Input`, `Button` | Multi-option dropdown | `label` (req), `options`, `selectedOptions`, `onSelectOptions` |
|
|
25
|
+
| `Form.NestedSelect` | `form-nested-select` | hierarchical select, tree select, nested dropdown, category select | — | Parent–child option dropdown | `label` (req), `options` (nested tree) |
|
|
26
|
+
| `Form.NestedMultiSelect` | `form-nested-multi-select` | hierarchical multi-select, nested multi-choice | — | Multi-select variant of nested dropdown | `label` (req), `options` (nested tree), `selectedOptions` |
|
|
27
|
+
| `Form.PredictiveTextInput` | `form-predictive-text-input` | autocomplete, typeahead, search with suggestions, live search | — | Text input with async suggestion fetch | `label` (req), `fetchOptions` (async fn), `onSelectOption` |
|
|
28
|
+
| `Form.MaskedInput` | `form-masked-input` | masked field, NRIC field, redacted input, hidden value | — | Partially masked value with reveal toggle | `label` (req), `maskRange`, `value`, `onChange` |
|
|
29
|
+
| `Form.OtpVerification` | `form-otp-verification` | OTP, one-time password, verification code, 2FA | — | Full OTP send-and-verify flow | `label` (req), `length`, `onComplete` |
|
|
30
|
+
| `Form.ESignature` | `form-e-signature` | signature pad, e-signature, digital signature, sign | — | Signature capture canvas — returns base64 | `label` (req), `onResult` |
|
|
31
|
+
| `Input` | `input` | standalone input, bare input | — | Text input without label — use `Form.Input` in forms | `value`, `onChange` |
|
|
32
|
+
| `OtpInput` | `otp-input` | OTP field, one-time password, verification code, 2FA | — | Individual OTP digit inputs with countdown | `numOfInput` (req), `cooldownDuration`, `onChange` |
|
|
33
|
+
|
|
34
|
+
---
|
|
35
|
+
|
|
36
|
+
## Form — Numbers & Units
|
|
37
|
+
|
|
38
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
39
|
+
| ----------------------- | ------------------------- | ------------------------------------------------------ | ------------ | ------------------------------------------------- | ------------------------------------------------ |
|
|
40
|
+
| `Form.Slider` | `form-slider` | slider, range input, numeric slider, range slider | `Form.Input` | Slider for a single numeric value | `label` (req), `min`, `max`, `value`, `onChange` |
|
|
41
|
+
| `Form.PhoneNumberInput` | `form-phone-number-input` | phone input, mobile number, country code, tel | — | Phone number with country code selector | `label` (req), `value`, `onChange` |
|
|
42
|
+
| `Form.UnitNumberInput` | `form-unit-number-input` | unit number, floor unit, #floor-unit, apartment number | — | Specialised input for Singapore floor-unit format | `label` (req), `value`, `onChange` |
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## Form — Dates & Times
|
|
47
|
+
|
|
48
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
49
|
+
| ---------------------- | ------------------------ | ----------------------------------------------------- | ---------------------------- | -------------------------------------------------------------------- | --------------------------------------------------- |
|
|
50
|
+
| `Form.DateInput` | `form-date-input` | date picker, date field, calendar input, datepicker | `Calendar` | Single date with calendar picker | `label` (req), `value`, `onChange`, `disabledDates` |
|
|
51
|
+
| `Form.DateRangeInput` | `form-date-range-input` | date range, start end date, date period, from to date | `Calendar` | Paired start/end date pickers — 3 variants: range, week, fixed-range | `label` (req), `value`, `onChange`, `variant` |
|
|
52
|
+
| `Form.TimePicker` | `form-timepicker` | time input, time field, time picker, hour minute | `Form.DateInput` | Time input — 12hr or 24hr | `label` (req), `value`, `onChange`, `format` |
|
|
53
|
+
| `Form.TimeRangePicker` | `form-time-range-picker` | time range, start end time, from to time | `Form.DateInput`, `Calendar` | Paired start/end time pickers | `label` (req), `value`, `onChange` |
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
## Form — Selection & Upload
|
|
58
|
+
|
|
59
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
60
|
+
| ------------- | -------------- | --------------------------------------------------------------- | --------------------- | ------------------------------------------------------------------------------ | ------------------------------------------------------------ |
|
|
61
|
+
| `Toggle` | `toggle` | option card, checkbox card, radio card, yes/no, selectable card | `Form.Input` | **Preferred** for checkbox/radio inputs in forms — renders as selectable card | `indicator` (req), `title`, `checked`, `onChange` |
|
|
62
|
+
| `Checkbox` | `checkbox` | checkmark, tick box, tick | `DataTable`, `Filter` | Compact boolean — use for table row selection or filter lists, not form fields | `checked`, `onChange` |
|
|
63
|
+
| `RadioButton` | `radio-button` | radio, single choice, radio group | `Filter` | Compact single-choice — use `Toggle` for form cards | `value`, `checked`, `onChange` |
|
|
64
|
+
| `FileUpload` | `file-upload` | file input, drag and drop, attachment, upload | `Alert`, `Button` | Drag-and-drop upload area — parent manages file state | `label` (req), `accept`, `multiple`, `fileItems`, `onUpload` |
|
|
65
|
+
|
|
66
|
+
---
|
|
67
|
+
|
|
68
|
+
## Data Display
|
|
69
|
+
|
|
70
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
71
|
+
| -------------- | --------------- | ---------------------------------------------------------- | -------------------------------- | -------------------------------------------------------------------------------- | ---------------------------------------------------- |
|
|
72
|
+
| `Card` | `card` | panel, content box, content card, surface | `Typography`, `Button`, `Layout` | Container for grouping related content | `children` |
|
|
73
|
+
| `Accordion` | `accordion` | collapsible, expandable, disclosure, FAQ | `Typography` | Multiple grouped collapsible panels | `items` (req — `{title, content}[]`) |
|
|
74
|
+
| `BoxContainer` | `box-container` | collapsible section, collapsible panel, expandable section | `Typography`, `Alert` | Single collapsible section — supports Edit CTA, error/warning state | `title` (req), `collapsible`, `expanded`, `onToggle` |
|
|
75
|
+
| `Timeline` | `timeline` | step list, event history, process steps, progress list | `Typography` | Vertical sequence of events or steps | `items` (req) |
|
|
76
|
+
| `LinkList` | `link-list` | related links, link group, resource list | `Card` | Styled list of links with descriptions and show-more toggle | `items` (req — `{title, href, description}[]`) |
|
|
77
|
+
| `Typography` | `typography` | text, heading, body text, paragraph, label, caption | `Colour` tokens | Text components — `HeadingXXL`→`HeadingXS`, `BodyBL`→`BodyXS`, `LinkBL`→`LinkXS` | `weight`, `as` (override element) |
|
|
78
|
+
| `Badge` | `badge` | count badge, notification dot, number badge, unread count | `Navbar`, `Button (icon)` | Numeric badge overlaid on another element | `value` (req) |
|
|
79
|
+
| `Avatar` | `avatar` | user avatar, profile picture, initials, profile icon | `Navbar` | User representation — image or initials fallback | `name` or `imageUrl` |
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
## Notifications & Status
|
|
84
|
+
|
|
85
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
86
|
+
| -------------------- | --------------------- | ----------------------------------------------------------------- | ------------------- | ----------------------------------------------- | ---------------------------------------------------------------------- |
|
|
87
|
+
| `Alert` | `alert` | inline alert, callout, info box, warning box, banner message | `Form`, `Button` | Inline callout — info/warning/success/error | `type` (req: `"info"/"warning"/"success"/"error"`), `children` |
|
|
88
|
+
| `Toast` | `toast` | snackbar, flash message, notification, pop-up message | `Button` | Transient auto-dismissing notification | `id`, `message` (req), `type` |
|
|
89
|
+
| `NotificationBanner` | `notification-banner` | banner, announcement, top banner, system banner | `Navbar` | Persistent banner below Navbar | `type` (req), `children` |
|
|
90
|
+
| `Pill` | `pill` | status pill, status label, status badge, chip | `Card`, `DataTable` | Static status label — 1–2 words, no interaction | `color`, `children` |
|
|
91
|
+
| `Tag` | `tag` | filter chip, category label, filter tag, keyword tag | `Filter`, `Card` | Category/filter label — static or interactive | `colorType`, `removable`, `onRemove`, `children` |
|
|
92
|
+
| `ProgressIndicator` | `progress-indicator` | stepper, step indicator, progress steps, wizard steps, multi-step | `Button`, `Form` | Step-by-step progress tracker | `steps` (req), `currentIndex` (req, 0-based), `displayExtractor` (req) |
|
|
93
|
+
|
|
94
|
+
---
|
|
95
|
+
|
|
96
|
+
## Navigation
|
|
97
|
+
|
|
98
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
99
|
+
| ------------ | ------------ | -------------------------------------------------- | ----------------------------- | ------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- |
|
|
100
|
+
| `Navbar` | `navbar` | top nav, navigation bar, header, app bar | `Masthead`, `Footer` | Top navigation — every page must include this | `resources.primary.brandName`, `items.desktop` |
|
|
101
|
+
| `Footer` | `footer` | page footer, bottom bar | `Navbar` | Page footer — `<Footer />` with no props for standard variant | _(none required)_ |
|
|
102
|
+
| `Breadcrumb` | `breadcrumb` | wayfinding, breadcrumb trail, crumbs | `Navbar` | Hierarchical location breadcrumb | `items` (req — `{label, href}[]`) |
|
|
103
|
+
| `Sidenav` | `sidenav` | sidebar navigation, side menu, left nav | `Layout` | Vertical sidebar navigation — 4-level nesting | `items` (req), `selectedId` |
|
|
104
|
+
| `Tab` | `tab` | tabs, tabbed navigation, tab strip, tab bar | `Filter`, `DataTable` | Tabbed content switching | `items` (req), `activeTabKey`, `onClickTab` |
|
|
105
|
+
| `LocalNav` | `local-nav` | in-page nav, anchor links, section nav, jump links | `Layout` | In-page section navigation | `items` (req — `{id, label}[]`) |
|
|
106
|
+
| `Menu` | `menu` | dropdown menu, context menu, action menu | `Button` | Dropdown menu attached to a trigger | `items` (req), `trigger` (req) |
|
|
107
|
+
| `Pagination` | `pagination` | page controls, paging, page numbers | `DataTable`, `Filter`, `Card` | Page navigation controls — always set `showFirstAndLastNav` | `totalItems` (req), `pageSize` (req), `activePage`, `onPageChange`, `showFirstAndLastNav` (req) |
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
## Overlays
|
|
112
|
+
|
|
113
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
114
|
+
| --------- | --------- | --------------------------------------------- | ------------------- | --------------------------------------------------- | ---------------------------------------------------- |
|
|
115
|
+
| `Modal` | `modal` | dialog, popup, lightbox, confirmation dialog | `Button`, `Form` | Full overlay dialog — blocks background interaction | `show` (req); nest `Modal.Box` with `onClose` inside |
|
|
116
|
+
| `Drawer` | `drawer` | side sheet, slide-in panel, tray, side drawer | `Filter`, `Sidenav` | Slide-in panel from screen edge | `show` (req), `onClose` |
|
|
117
|
+
| `Popover` | `popover` | anchored popup, floating panel, overlay panel | `Button` | Anchored floating content panel | `trigger` (req), `content` (req) |
|
|
118
|
+
|
|
119
|
+
---
|
|
120
|
+
|
|
121
|
+
## Filters & Search
|
|
122
|
+
|
|
123
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
124
|
+
| --------- | -------- | ------------------------------------------------------------ | ------------------------------------------------------------ | -------------------------------------------------------- | ------------------------------- |
|
|
125
|
+
| `Filter` | `filter` | filter panel, filter sidebar, faceted search, search filters | `DataTable`, `Pagination`, `Card`, `Checkbox`, `RadioButton` | Filter UI — auto-switches desktop sidebar / mobile modal | `items` (req), `onFilterChange` |
|
|
126
|
+
|
|
127
|
+
---
|
|
128
|
+
|
|
129
|
+
## Specialist / Complex
|
|
130
|
+
|
|
131
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
132
|
+
| ------------------------- | --------------------------- | -------------------------------------------------------------------------------- | ------------------------------------------ | ------------------------------------------------------------------------------------------ | ---------------------------------------------------------------- |
|
|
133
|
+
| `DataTable` | `data-table` | sortable table, data grid, table with selection | `Pagination`, `Filter`, `Checkbox`, `Pill` | Sortable, configurable data table with row selection | `columns` (req), `data` (req) |
|
|
134
|
+
| `Table` | `table` | basic table, html table, simple table | `Typography` | Basic styled table wrapper | `children` |
|
|
135
|
+
| `Calendar` | `calendar` | date calendar, month view, date picker calendar | `Form.DateInput`, `Form.DateRangeInput` | Full calendar month view — single or multi-select | `value`, `onSelect`, `disabledDates` |
|
|
136
|
+
| `DateNavigator` | `date-navigator` | date stepper, prev next date, date arrow | `Calendar` | Prev/next date navigation control | `value` (req), `onPrev`, `onNext` |
|
|
137
|
+
| `TimeSlotBar` | `time-slot-bar` | time slots, booking slots, availability bar | `Calendar`, `Form.DateInput` | Horizontal time slot selection bar | `slots` (req), `selectedSlot`, `onSelectSlot` |
|
|
138
|
+
| `TimeSlotBarWeek` | `time-slot-bar-week` | week slots, weekly time slots | `Calendar` | Week-view time slot bar | `slots` (req), `selectedSlot`, `onSelectSlot` |
|
|
139
|
+
| `TimeSlotWeekView` | `time-slot-week-view` | week view, weekly calendar, weekly availability | `Calendar` | Full week-view time slot grid | `slots` (req), `selectedSlot`, `onSelectSlot` |
|
|
140
|
+
| `Timetable` | `timetable` | schedule grid, period grid, class timetable | — | Timetable / period grid display | `data` (req) |
|
|
141
|
+
| `Schedule` | `schedule` | daily schedule, time schedule, day view | `Calendar` | Daily schedule display | `data` (req), `date` |
|
|
142
|
+
| `ErrorDisplay` | `error-display` | error page, empty state, no results, 404, 500, maintenance page, session timeout | `Button` | Full-page or section error/empty state — covers HTTP errors, empty results, session states | `type` (req: `"404"/"500"/"maintenance"/"no-results"/"timeout"`) |
|
|
143
|
+
| `FeedbackRating` | `feedback-rating` | star rating, rating widget, feedback, satisfaction survey | `Modal`, `Toast` | Rating/feedback capture widget | `rating`, `onRatingChange` |
|
|
144
|
+
| `CountdownTimer` | `countdown-timer` | timer, countdown, time remaining, session timer | `Alert`, `Modal` | Countdown display | `targetDate` or `duration` (req) |
|
|
145
|
+
| `FileDownload` | `file-download` | download link, file download, attachment download | `Card` | File download link/button | `filename` (req), `fileUrl` (req) |
|
|
146
|
+
| `FullscreenImageCarousel` | `fullscreen-image-carousel` | image carousel, lightbox gallery, photo gallery | `Card`, `Button` | Fullscreen image carousel — discriminated union items | `items` (req — discriminated union), `show`, `onClose` |
|
|
147
|
+
| `UnEditableSection` | `uneditable-section` | read-only field, display field, view mode, review field | `Form`, `Card` | Read-only field display for review screens | `items` (req — `{label, value, displayWidth}[]`) |
|
|
148
|
+
|
|
149
|
+
---
|
|
150
|
+
|
|
151
|
+
## Branding & Platform
|
|
152
|
+
|
|
153
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
154
|
+
| ------------------ | ------------------- | -------------------------------------------------- | ---------- | ----------------------------------------------------------- | --------------------------------------------- |
|
|
155
|
+
| `SingpassButton` | `singpass-button` | Singpass login, Myinfo button, Singpass | — | Pre-built Singpass login button — do not custom style | _(none — do not custom style)_ |
|
|
156
|
+
| `SmartAppBanner` | `smart-app-banner` | app download banner, mobile app banner, app store | `Navbar` | App store download prompt banner | `show`, `appStoreUrl`, `playStoreUrl` |
|
|
157
|
+
| `Masthead` | `masthead` | gov.sg masthead, government masthead, sgd masthead | `Navbar` | Official gov.sg masthead — required for government services | _(none required)_ |
|
|
158
|
+
| `LanguageSwitcher` | `language-switcher` | language selector, locale switcher, bilingual | `Navbar` | Language/locale selection control | `items` (req), `selectedLanguage`, `onSelect` |
|
|
159
|
+
|
|
160
|
+
---
|
|
161
|
+
|
|
162
|
+
## Layout & Utility
|
|
163
|
+
|
|
164
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
165
|
+
| ----------------- | ------------------ | --------------------------------------------------------------------------- | -------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------- |
|
|
166
|
+
| `Layout` | `layout` | grid, container, column, responsive layout, col | `Card`, `Typography` | Responsive grid — `Layout.Container type="grid"` + `Layout.ColDiv xsCols` | `Layout.Container type` (req), `Layout.ColDiv xsCols lgCols` |
|
|
167
|
+
| `TextList` | `text-list` | bullet list, unordered list, ordered list, numbered list, ul, ol | `Typography`, `Card` | Semantic lists — `TextList.Ul` (bullets) and `TextList.Ol` (numbered/lettered). Supports custom icon bullets | `items` (req), `listStyleType` |
|
|
168
|
+
| `HistogramSlider` | `histogram-slider` | range slider with histogram, price range, distribution slider, filter range | `Filter` | Range slider with histogram chart above — for filter panels where showing value distribution aids range selection | `min` (req), `max` (req), `value`, `onChange`, `histogramData` |
|
|
169
|
+
| `Divider` | `divider` | horizontal rule, separator, hr, line | `Card`, `Accordion` | Visual separator between sections | _(none required)_ |
|
|
170
|
+
| `ImageButton` | `image-button` | image CTA, image card button, clickable image | `Layout` | Image with text overlay as a button | `imageUrl` (req), `label`, `onClick` |
|
|
171
|
+
| `Table` | `table` | basic table, html table, simple table, read-only table | `Typography` | Styled HTML table wrapper — `Table.Container` + `Table` + `Table.Head/Body/Row/HeaderCell/Cell`. No sorting or selection — use `DataTable` for those | `children` |
|
|
172
|
+
| `DashedBorder` | `dashed-border` | dashed outline, drop zone border, placeholder region | `FileUpload` | Container with dashed SVG border — for drop zones, placeholder regions, or empty-state containers | `children` |
|
|
173
|
+
|
|
174
|
+
---
|
|
175
|
+
|
|
176
|
+
## Icons
|
|
177
|
+
|
|
178
|
+
| Component | Key | Also known as | Pairs with | Description | Key props |
|
|
179
|
+
| ----------- | ----------- | ---------------------------------------------------------------------- | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------- |
|
|
180
|
+
| Icons | `icon` | icon, svg icon, react icon, arrow icon, tick icon, MUI | `Button`, `Navbar` | Icons from `@lifesg/react-icons` — separate package. Each icon is its own named export: `import { ArrowRightIcon } from "@lifesg/react-icons/arrow-right"`. Never guess names — read the resource file. | `aria-label` (for standalone icons) |
|
|
181
|
+
| `Animation` | `animation` | loading spinner, spinner, loading indicator, animate, transition, dots | — | Loading and transition animations — `LoadingSpinner`, `LoadingDots`, `LoadingDotsSpinner`. Import from `@lifesg/react-design-system/animations` | _(none required)_ |
|