pl-fe: reduce nested elements part 2

Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
nicole mikołajczyk
2025-10-19 19:39:24 +02:00
parent f062331f54
commit a6f93fd3c7
2 changed files with 5 additions and 7 deletions

View File

@ -151,7 +151,7 @@ const ModalRoot: React.FC<IModalRoot> = ({ children, onCancel, onClose, type })
};
const getSiblings = () => Array(...(ref.current!.parentElement!.childNodes as any as ChildNode[]))
.filter(node => (node as HTMLDivElement).id !== 'toaster')
.filter(node => (node as HTMLDivElement).id !== '_rht_toaster')
.filter(node => node !== ref.current);
useEffect(() => {

View File

@ -60,12 +60,10 @@ const PlFeMount = () => {
<ModalRoot />
</Suspense>
<div id='toaster'>
<Toaster
position='top-right'
containerClassName='top-4'
/>
</div>
<Toaster
position='top-right'
containerClassName='top-4'
/>
</Route>
</Switch>
</ScrollContext>