NoticeBubble
Components4.7.8
NoticeBubbleManager
import NoticeBubbleManager from '@semcore/ui/notice-bubble';
Manager is a storage of all notice instances, it is able to add, delete and update notices by calling the appropriate methods.
interface
INoticeBubbleManager
Property | Description |
---|---|
add* (props: INoticeBubbleInfoProps | INoticeBubbleWarningProps) => {uid: stringupdate: (props: Partial<INoticeBubbleInfoProps> | Partial<INoticeBubbleWarningProps>) => booleanremove: () => boolean} | Creates and shows a notice. |
update* (uid: string, props: Partial<INoticeBubbleInfoProps> | Partial<INoticeBubbleWarningProps>) => boolean | Updates notice by uid. |
remove* (uid: string) => boolean | Removes notice by uid. |
NoticeBubbleContainer
import { NoticeBubbleContainer } from '@semcore/ui/notice-bubble';
Container - div in the body via the portal (React.Portal
). It is inserted once in any part of the application and subscribes to Manager updates (NoticeBubbleManager
). Later, notices will be rendered to it.
interface
INoticeBubbleContainerProps extends IBoxProps
, IPortalProps
Property | Description |
---|---|
manager | Manager copy |
locale string |