Tags: patternfly/react-component-groups
Tags
fix: trigger 6.5.0-prerelease.1
fix(ResponsiveActions): Disable kebab when all actions are disabled (#… …928) * fix(ResponsiveActions): Disable kebab when all actions are disabled Fixes #927 - Uses OverflowMenuContext to access isBelowBreakpoint state - Kebab disabled state is now responsive to viewport width: - Above breakpoint: disabled if all regular items are disabled - Below breakpoint: disabled if all items (pinned + regular) are disabled - Created ResponsiveActionsDropdown component to access context - Tracks disabled state separately for pinned vs regular items - Added comprehensive test coverage for all scenarios - Fully backward compatible (no breaking changes) * refactor: remove unnecessary comments from ResponsiveActions Address PR review feedback by removing unnecessary comments that don't add value beyond what the code already expresses. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * test(ResponsiveActions): use RTL conventions and remove unnecessary snapshots Address PR review feedback: - Replace container.querySelector with screen.getByRole('button') queries - Remove snapshot tests from disabled state tests (structure is tested by other tests) - Remove container destructuring where no longer needed - Use toBeDisabled()/toBeEnabled() instead of toHaveAttribute('disabled') Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
fix(ResponsiveActions): Disable kebab when all actions are disabled (#… …928) * fix(ResponsiveActions): Disable kebab when all actions are disabled Fixes #927 - Uses OverflowMenuContext to access isBelowBreakpoint state - Kebab disabled state is now responsive to viewport width: - Above breakpoint: disabled if all regular items are disabled - Below breakpoint: disabled if all items (pinned + regular) are disabled - Created ResponsiveActionsDropdown component to access context - Tracks disabled state separately for pinned vs regular items - Added comprehensive test coverage for all scenarios - Fully backward compatible (no breaking changes) * refactor: remove unnecessary comments from ResponsiveActions Address PR review feedback by removing unnecessary comments that don't add value beyond what the code already expresses. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * test(ResponsiveActions): use RTL conventions and remove unnecessary snapshots Address PR review feedback: - Replace container.querySelector with screen.getByRole('button') queries - Remove snapshot tests from disabled state tests (structure is tested by other tests) - Remove container destructuring where no longer needed - Use toBeDisabled()/toBeEnabled() instead of toHaveAttribute('disabled') Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
feat(BulkSelect): extend onSelect with second parameter source (#913) * feat(BulkSelect): extend onSelect API with source param * test(BulkSelect): add unit tests for source Assisted-by: Cursor * refactor: define BulkSelectSource as a value Co-authored-by: Karel Hala <ch4rlien@gmail.com> * refactor: use BulkSelectSource.dropdown instead of literal Co-authored-by: Karel Hala <ch4rlien@gmail.com> * refactor: use BulkSelectSource.checkbox instead of literal Co-authored-by: Karel Hala <ch4rlien@gmail.com> * refactor: add BulkSelectSource type * test: update BulkSelect unit tests --------- Co-authored-by: Karel Hala <ch4rlien@gmail.com>
feat(BulkSelect): disable Select none option when no rows are selected ( #914) * feat(BulkSelect): disable Select none when no rows are selected * test(BulkSelect): add unit tests for disabling Select none option AssistedBy: Cursor
feat(BulkSelect): add internationalization (i18n) support (#896) Adds optional props for customizing all user-facing strings in BulkSelect to support internationalization and custom terminology. All changes are backward compatible with sensible English defaults. New props: - selectNoneLabel: Custom label for "Select none" option - selectPageLabel: Function receiving pageCount to format "Select page" label - selectAllLabel: Function receiving totalCount to format "Select all" label - selectedLabel: Function receiving selectedCount to format the displayed count Implementation details: - Default label functions are hoisted to module level for stable references - Label functions are called inside useMemo to prevent unnecessary re-renders - Optimized for performance with expensive operations like pseudolocalization - Parameter names avoid i18n reserved keywords (e.g., 'count' for pluralization) Fixes #895 Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
fix(ResponsiveAction): resolve warning about accessing reserved 'key'… … prop (#892) Fixes #890 The ResponsiveAction component was incorrectly defining 'key' as a prop in its interface, which caused React to warn when developers used the standard key prop pattern with arrays of ResponsiveAction components. Changes: - Removed 'key' from ResponsiveActionProps interface since 'key' is a reserved React prop that cannot be accessed within components - Updated ResponsiveActions to use child.key instead of child.props.key to access React's internal key value without triggering warnings Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
fix(ResponsiveActions): prevent empty dropdown when all actions are p… …ersistent or pinned (#889) Fixes #888 When all ResponsiveAction components had isPersistent or isPinned props, an empty kebab dropdown was still being rendered. Root Cause: The hasAdditionalOptions prop on OverflowMenuControl was forcing the dropdown control to always show, even when there were no regular overflow actions (only persistent/pinned actions that don't need a persistent dropdown). Changes: - Conditionally set hasAdditionalOptions based on presence of regular actions - Track hasRegularActions boolean to distinguish action types - Only set hasAdditionalOptions={true} when regular actions are present - Added early return guard to prevent rendering empty OverflowMenu - Added tests for persistent-only, pinned-only, and mixed action scenarios Behavior: - Regular actions: hasAdditionalOptions={true} → dropdown always renders - Only persistent: hasAdditionalOptions={false} → no dropdown - Only pinned: hasAdditionalOptions={false} → dropdown managed by OverflowMenu - Mixed persistent/pinned: hasAdditionalOptions={false} → dropdown managed by OverflowMenu Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
PreviousNext