PBCProvider
Combined dialog and notification provider.
Place it once above components that show dialogs and notifications. Pass settings through dialog and notifications.
Live example
Example controls
Usage
import { Button, PBCProvider } from '@prosazhin/pbcomponents';
function App() {
return (
<PBCProvider notifications={{ top: 20 }}>
<Button>Ready</Button>
</PBCProvider>
);
}Component API
| Prop | Type / variants | Purpose | Default |
|---|---|---|---|
children | ReactNode | Application children. | — |
dialog | DialogProviderProps | DialogProvider settings such as animationDuration. | — |
notifications | NotificationsProviderProps | NotificationsProvider settings: top, delay, animation and timer. | — |
Native HTML attributes are accepted where the component renders the corresponding element. className props only affect styling.