Origami Frontend Components & Services

JSDoc: n-alert-banner

n-alert-banner is not maintained by the Origami team. This means that the Origami team will not necessarily be able to help you with support requests. The people who maintain this component may be able to offer support, but it's not guaranteed.

n-alert-banner has a support status of "experimental". This means that the component's API may change without notice, and there is no guarantee that the component is ready for production use.

new AlertBanner(alertBannerElement, options)

Represents a alertBanner.

Class constructor.

parameter type default description
alertBannerElement (optional) HTMLElement The alertBanner element in the DOM
options (optional) Object {} An options object for configuring the alertBanner

Methods

Links

AlertBanner#render

Instance Method

Render the alertBanner.

Links

AlertBanner#open

Instance Method

Open the alert banner.

Links

AlertBanner#close

Instance Method

Close the alertBanner.

Links

AlertBanner.init(rootElement, options)

Static Method

Initialise alertBanner components.

parameter type default description
rootElement HTMLElement | String The root element to intialise banners in, or a CSS selector for the root element
options (optional) Object {} An options object for configuring the banners

Links

module.exports

Static Property

Build a close button element.

Links

module.exports

Static Property

Get the data attributes from the alertBannerElement. If the alertBanner is being set up declaratively, this method is used to extract the data attributes from the DOM.

Links

Switch component view

GitHub Repository

Install n-alert-banner

If using the Build Service, add n-alert-banner@^1.0.0 to your script and link tags.

If running a Manual Build, run bower install --save "n-alert-banner@^1.0.0".

Help & Support

n-alert-banner is not supported directly by the Origami team. We make no guarantees, but will help if we can. First try contacting its maintainers at:

Slack: #ft-next-conversion
Email: conversion.tech@ft.com