Skip to content

Notice

Notice

jsx
import Notice from 'intergalactic/notice';
<Notice />;
import Notice from 'intergalactic/notice';
<Notice />;

NoticeProps

& & {...}
NameTypeDescription
hiddenboolean Property for managing visibility of Notice
useDeprecated Notice type
theme Notice theme
durationnumber Duration of animation, ms
localestring

Notice.Label

The component is inherited from Box and is used to insert a label in the left part of the notice (usually, an icon).

jsx
import Notice from 'intergalactic/notice';
<Notice.label />;
import Notice from 'intergalactic/notice';
<Notice.label />;

Notice.Actions

The component is inherited from Box and is used to insert control components in the lower part of the notice. Usually, it's a button or a group of buttons.

jsx
import Notice from 'intergalactic/notice';
<Notice.Actions />;
import Notice from 'intergalactic/notice';
<Notice.Actions />;

Notice.Content

The component is inherited from Box and is used to insert content in the notice.

jsx
import Notice from 'intergalactic/notice';
<Notice.Content />;
import Notice from 'intergalactic/notice';
<Notice.Content />;

Notice.CloseIcon

The component is inherited from Box and is used to insert the Close button.

jsx
import Notice from 'intergalactic/notice';
<Notice.CloseIcon />;
import Notice from 'intergalactic/notice';
<Notice.CloseIcon />;

NoticeSmart

A more convenient component version with posibility to define features through props. For more details, refer to the example.

jsx
import { NoticeSmart } from 'intergalactic/notice';
<NoticeSmart />;
import { NoticeSmart } from 'intergalactic/notice';
<NoticeSmart />;

NoticeSmartProps

& {...}
NameTypeDescription
labelReact.ReactNode A custom element for additional information
actionsReact.ReactNode Custom action element
closableboolean Adds a Close icon
onClose(event: React.SyntheticEvent) => void Callback on a click on the close button

Released under the MIT License.

Released under the MIT License.