Changelog
All notable changes to this project are documented here. The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
This page mirrors
CHANGELOG.mdin the repository.
[2.0.0] — unreleased
Breaking release. See the Migration Guide for upgrade steps.
Removed
- [Sidebar] Removed the
ProSidebarProvidercomponent (deprecated since 1.1) - Removed the
useProSidebarhook (deprecated since 1.1) — useSidebarprops instead - [Sidebar] Removed the
defaultCollapsedprop — use the controlledcollapsedprop - [Sidebar] Removed the
breakPoint="always"value — usebreakPoint="all" - [Sidebar] Removed the
customBreakPointprop — pass a custom value tobreakPointinstead (e.g.breakPoint="450px")
Changed
- Breaking: React peer dependency is now
>=18(dropped React 16 / 17 support); React 19 is supported - Runtime dependencies (
@emotion,@popperjs,classnames) are now externalized instead of bundled, reducing install size and avoiding duplicate copies - The package now ships a proper
exportsmap with ESM (dist/index.mjs), CJS (dist/index.js) and atypesentry
Added
- [Menu] New
popoverprop — top-levelSubMenus open as floating poppers even when the sidebar is expanded (instead of sliding open inline) - [Menu] New
accordionprop — when set, only one top-levelSubMenucan be open at a time. Opening another closes the previously open one - [SubMenu] New
accordionprop — coordinates only the submenu’s direct children (per-level scope, independent of any ancestor accordion) - [SubMenu] Active state now cascades automatically — a
SubMenuis marked active whenever any of its descendants is active - [Sidebar] Pressing
Escapenow closes the sidebar when open as an overlay (broken + toggled) - [Sidebar] Focus moves into the sidebar when it opens as an overlay
- [MenuItem]
aria-current="page"on active items andaria-disabledon disabled items - [SubMenu]
aria-expandedon the trigger,aria-haspopup="menu"when a collapsed top-level submenu opens as a popup, andaria-disabledon disabled triggers
Fixed
- [Sidebar] Backdrop now uses
onKeyDownand activates only onEnter/Space(replacing the deprecatedonKeyPress, which fired on any key) - [SubMenu] Items in a closed submenu are no longer reachable via Tab or exposed to
screen readers — the closed submenu content is now marked
inert - [SubMenu] Trigger now has
role="button", so itsaria-expanded/aria-haspopupstate is valid (it previously sat on a roleless<a>)
[1.1.0] — 2024-02-03
Fixed
- Fixed submenu
openprop not working properly (issue #210)
[1.1.0-alpha.2] — 2024-01-22
Fixed
- Fixed
window is undefinedfrom @thiagobrito
[1.1.0-alpha.1] — 2023-05-20
Added
- [Sidebar] Added
collapsedprop - [Sidebar] Added
toggledprop - [Sidebar] Added
onBackdropClickprop - [Sidebar] Added
onBreakPointprop
Updated
- Deprecated
ProSidebarProviderand made it optional - Deprecated
useProSidebar - Updated
BreakPointtype to usealland deprecatealways
Fixed
- Fixed
closeOnClicktriggering close on nested SubMenu click - Fixed sidebar default states not being applied correctly when using
ProSidebarProvideranduseProSidebar - Fixed Menu’s
transitionDurationcollision with Sidebar’stransitionDuration
[1.0.0] — 2023-01-21
React Pro Sidebar 1.0.0 is here 🎉
For the full list of changes, browse changelogs matching 1.0.0-alpha.* and
1.0.0-beta.* below.
[1.0.0-beta.3] — 2023-01-20
- [SubMenu] fixed popper placement on RTL
[1.0.0-beta.2] — 2023-01-14
- [Menu] Added
transitionDurationprop to use when sliding submenu content
[1.0.0-beta.1] — 2023-01-13
- [MenuItem] Removed
routerLinkprop in favor ofcomponent - [SubMenu] Added
componentprop
[1.0.0-alpha.10] — 2023-01-10
- [MenuItem] [SubMenu] Apply root classes to child nodes (Button, label, prefix, …)
- [MenuItem] [SubMenu] Improve accessibility
- [Sidebar] Fix sidebar border not changing when
rtlis set to true
[1.0.0-alpha.9] — 2022-11-27
- Fix build
[1.0.0-alpha.8] — 2022-11-27
- Added
rootStylesto all components - [Sidebar] Added
backdropStyles - [Sidebar] Removed
overlayColorprop - [Menu] Renamed
renderMenuItemStylestomenuItemStyles(typeMenuItemStyles), which now applies styles directly to MenuItem / SubMenu components and their children
Type definition:
type ElementStyles =
| CSSObject
| ((params: MenuItemStylesParams) => CSSObject | undefined);
interface MenuItemStyles {
root?: ElementStyles;
button?: ElementStyles;
label?: ElementStyles;
prefix?: ElementStyles;
suffix?: ElementStyles;
icon?: ElementStyles;
subMenuContent?: ElementStyles;
SubMenuExpandIcon?: ElementStyles;
}- Updated classnames. The following are the new names:
ps-sidebar-root,ps-sidebar-container,ps-sidebar-image,ps-sidebar-backdrop,ps-collapsed,ps-toggled,ps-rtl,ps-broken,ps-menu-root,ps-menuitem-root,ps-submenu-root,ps-menu-button,ps-menu-prefix,ps-menu-suffix,ps-menu-label,ps-menu-icon,ps-submenu-content,ps-submenu-expand-icon,ps-disabled,ps-active,ps-open. - Added utility classes (
sidebarClasses,menuClasses) that can be used to reference the classes above.
[1.0.0-alpha.7] — 2022-10-24
- Added support for React Router to
MenuItemvia therouterLinkprop
[1.0.0-alpha.6] — 2022-10-14
- Fixed submenu content not displayed when collapsed (issue #124)
[1.0.0-alpha.4] — 2022-10-10
- Build updates, dependency upgrades, test fixes
[1.0.0-alpha.3] — 2022-10-06
- Fixed
childrenprop typing
[1.0.0-alpha.2] — 2022-10-05
- Fixed build
[1.0.0-alpha.1] — 2022-10-05
Breaking changes
- Removed SCSS in favor of css-in-js (styled component)
- [Sidebar] Renamed
ProSidebartoSidebar
- import { ProSidebar } from 'react-pro-sidebar';
+ import { Sidebar } from 'react-pro-sidebar';- [Sidebar] Removed
collapsed,toggledandonToggleprops (useProSidebarhook used instead) - [Sidebar] Added
defaultCollapsedprop - [Sidebar] Added
alwaysoption tobreakPointprop - [Sidebar] Added
customBreakPointprop - [Sidebar] Added
backgroundColorprop - [Sidebar] Added
transitionDurationprop - [Sidebar] Added
overlayColorprop - [Menu] Removed
iconShape,popperArrow,subMenuBulletsandinnerSubMenuArrowsprops - [Menu] Added
renderMenuItemStylesprop for customizingMenuItem&SubMenucomponents - [Menu] Added
renderExpandIconprop - [Menu] Added
closeOnClickprop (useful when wanting to close popper on MenuItem click when collapsed istrue) - [MenuItem] Added
disabledprop - [SubMenu] Added
disabledprop - [SubMenu] Renamed
titleprop tolabel - Introduced
ProSidebarProvidercomponent anduseProSidebarhook to access and manage sidebar state
[0.7.1] — 2021-09-23
Fixed
- Fix submenu items bullets not showing by adding
subMenuBulletsandinnerSubMenuArrowsprops to Menu to choose between arrows and bullets
[0.7.0] — 2021-09-22
Added
- Add submenu indent variable and update default
- Add exports for all component props
- Add
breakpoint-xxl
Updated
- Replace submenu bullets with arrows
- Enable icon use in submenu items
Fixed
- Fix TypeScript property collision by omitting prefix props for
lielement (@zirho)
[0.6.0] — 2021-02-11
Added
- Add
widthandcollapsedWidthprops
Fixed
- Fix dynamically adding
Menuitems depending on certain conditions (@sergiovhe) - Fix use of styles in
ProSidebarcomponent (@sujaysudheenda) - Fix default props spreading
[0.5.0] — 2020-12-14
Added
Fixed
- Fix prop spreading and update types on submenu
[0.4.4] — 2020-08-16
Fixed
- Fix
SidebarFooterstyling (issue #12) - Fix overlapping sidebar image with overlay
[0.4.3] — 2020-07-06
Fixed
- Fix CSS build
[0.4.2] — 2020-07-05
Fixed
- Fix
slidedown.csspath bug (issue #7)
[0.4.1] — 2020-06-12
Fixed
- Fix TypeScript error type (issue #3)
[0.4.0] — 2020-06-05
Added
- Display arrow on hover over top-level submenu title
- Add toggle option for sidebar and break points
- Add
popperArrowprop inMenuto specify whether to display an arrow when the sidebar is collapsed
Changed
- Use
direction: rtlinstead ofrow-reverse
Fixed
- Fix react-slidedown CSS import (issue #1) from @metadan
- Fix submenu positioning on sidebar collapsed using
popperjsandresize-observer-polyfillfor resize event listener
[0.3.0] — 2020-05-11
Added
- Add
suffixprop toMenuItemand submenu - Add
prefixprop toMenuItemand submenu - Add sidebar layout —
SidebarHeader,SidebarContent,SidebarFooter
[0.2.0] — 2020-05-08
Added
- Add
openprop to submenu component - Add
activeprop toMenuItemcomponent
Fixed
- Fix sidebar height overflow
[0.1.1] — 2020-05-07
Fixed
- Fix submenu visibility when collapsed
[0.1.0] — 2020-05-07
Added
- Add
defaultOpenprop to submenu component
Changed
- Update README — merge API tables into one, use
propinstead ofname, add nested submenu docs
Fixed
- Fix overflow of the sidebar content
[0.1.0-beta.1] — 2020-05-06
Initial pre-release
- Initial pre-release of the React Pro Sidebar library