Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit e457ffe

Browse filesBrowse files
committed
fix(CModal): disable emitting the onClose event twice
1 parent b1ede20 commit e457ffe
Copy full SHA for e457ffe

File tree

1 file changed

+1
-2
lines changed
Filter options
  • packages/coreui-react/src/components/modal

1 file changed

+1
-2
lines changed

‎packages/coreui-react/src/components/modal/CModal.tsx

Copy file name to clipboardExpand all lines: packages/coreui-react/src/components/modal/CModal.tsx
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,13 +158,12 @@ export const CModal = forwardRef<HTMLDivElement, CModalProps>(
158158
}, [_visible])
159159

160160
const handleDismiss = () => {
161+
console.log('handleDismiss')
161162
if (backdrop === 'static') {
162163
return setStaticBackdrop(true)
163164
}
164165

165166
setVisible(false)
166-
167-
return onClose && onClose()
168167
}
169168

170169
useLayoutEffect(() => {

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.