Skip to content

Commit

Permalink
Merge branch 'main' into chore/tearsheet-rename-ailabel-to-decorator
Browse files Browse the repository at this point in the history
  • Loading branch information
sangeethababu9223 authored Dec 24, 2024
2 parents 943ec50 + d341b15 commit 63a9b34
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 20 deletions.
8 changes: 8 additions & 0 deletions packages/ibm-products/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## [2.56.1](https://github.com/carbon-design-system/ibm-products/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-19)

**Note:** Version bump only for package @carbon/ibm-products





## [2.56.1-rc.0](https://github.com/carbon-design-system/ibm-products/compare/@carbon/[email protected]...@carbon/[email protected]) (2024-12-18)


Expand Down
2 changes: 1 addition & 1 deletion packages/ibm-products/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@carbon/ibm-products",
"description": "Carbon for IBM Products",
"version": "2.56.1-rc.0",
"version": "2.56.1",
"license": "Apache-2.0",
"main": "lib/index.js",
"module": "es/index.js",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import React from 'react';
import { StoryDocsPage } from '../../global/js/utils/StoryDocsPage';

import * as stories from './SidePanel';
import * as stories from './SidePanel.stories';

const DocsPage = () => (
<StoryDocsPage
Expand Down
34 changes: 16 additions & 18 deletions packages/ibm-products/src/components/SidePanel/SidePanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -553,7 +553,7 @@ export let SidePanel = React.forwardRef(
if (!open) {
onUnmount?.();
}
setAnimationComplete(true);
setAnimationComplete(!animationComplete);
};

// Set the internal state `animationComplete` to true if
Expand Down Expand Up @@ -631,26 +631,24 @@ export let SidePanel = React.forwardRef(
]);

useEffect(() => {
if (open) {
setTimeout(() => {
if (open && animationComplete) {
if (
selectorPrimaryFocus &&
getSpecificElement(sidePanelRef?.current, selectorPrimaryFocus)
) {
const primeFocusEl = getSpecificElement(
sidePanelRef?.current,
selectorPrimaryFocus
);
if (
selectorPrimaryFocus &&
getSpecificElement(sidePanelRef?.current, selectorPrimaryFocus)
primeFocusEl &&
window?.getComputedStyle(primeFocusEl)?.display !== 'none'
) {
const primeFocusEl = getSpecificElement(
sidePanelRef?.current,
selectorPrimaryFocus
);
if (
primeFocusEl &&
window?.getComputedStyle(primeFocusEl)?.display !== 'none'
) {
(primeFocusEl as HTMLElement)?.focus();
}
} else if (!slideIn) {
firstElement?.focus();
setTimeout(() => primeFocusEl?.focus(), 0);
}
}, 0);
} else if (!slideIn) {
setTimeout(() => firstElement?.focus(), 0);
}
}
}, [
animationComplete,
Expand Down
4 changes: 4 additions & 0 deletions packages/ibm-products/telemetry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -456,14 +456,17 @@ collect:
- editButtonText
- editing
- editSuccess
- editSuccessMessage
- editSuccessTitle
- errorText
- generateButtonText
- generateSuccessBody
- generateSuccessMessage
- generateSuccessTitle
- generateTitle
- hasAPIKeyVisibilityToggle
- hasDownloadLink
- helperText
- hideAPIKeyLabel
- loadingText
- modalLabel
Expand Down Expand Up @@ -532,6 +535,7 @@ collect:
- fixedIsVisible
# CoachmarkOverlayElements
- isVisible
- onBack
# CoachmarkStackHome
- onClickNavItem
# Columns
Expand Down

0 comments on commit 63a9b34

Please sign in to comment.