How to use bpk-component-banner-alert - 10 common examples

To help you get started, we’ve selected a few bpk-component-banner-alert examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
constructor() {
    super();

    this.bannerAlerts = [
      {
        show: true,
        message: 'Neutral alert with dismiss option.',
        type: ALERT_TYPES.NEUTRAL,
      },
      {
        show: true,
        message: 'Successful alert with dismiss option.',
        type: ALERT_TYPES.SUCCESS,
      },
      {
        show: true,
        message: 'Warn alert with dismiss option.',
        type: ALERT_TYPES.WARN,
      },
      {
        show: true,
        message: 'Error alert with dismiss option.',
        type: ALERT_TYPES.ERROR,
      },
    ];

    this.state = {
      bannerAlerts: JSON.parse(JSON.stringify(this.bannerAlerts)),
      dirty: false,
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
}

const components = [
  {
    id: 'default',
    title: 'Default',
    blurb: [
      
        Banner alerts come in four styles to indicate success, warning or error,
        or some neutral information.
      ,
    ],
    examples: [
      ,
      ,
      ,
      ,
      ,
    ],
  },
  {
    id: 'expandable',
    title: 'Expandable',
    blurb: [
      
        They can be configured to display further information to the user in the
        form of an expandable panel.
      ,
    ],
    examples: [
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
examples: [
      
        {longMessage}
      ,
      
        {longMessage}
      ,
      
        {longMessage}
      ,
      
        {longMessage}
      ,
    ],
  },
  {
    id: 'dismissable',
    title: 'Dismissable',
    blurb: [
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
this.bannerAlerts = [
      {
        show: true,
        message: 'Neutral alert with dismiss option.',
        type: ALERT_TYPES.NEUTRAL,
      },
      {
        show: true,
        message: 'Successful alert with dismiss option.',
        type: ALERT_TYPES.SUCCESS,
      },
      {
        show: true,
        message: 'Warn alert with dismiss option.',
        type: ALERT_TYPES.WARN,
      },
      {
        show: true,
        message: 'Error alert with dismiss option.',
        type: ALERT_TYPES.ERROR,
      },
    ];

    this.state = {
      bannerAlerts: JSON.parse(JSON.stringify(this.bannerAlerts)),
      dirty: false,
    };
  }
github Skyscanner / backpack / packages / bpk-docs / src / pages / FormsPage / FormsPage.js View on Github external
<option value="business">Business class</option>
          <option value="first">First class</option>
        
      ,
    ],
    readme: selectReadme,
  },
  {
    id: 'docked-inputs-and-selects',
    title: 'Docked inputs &amp; selects',
    blurb:
      'Both inputs and selects can be docked together to build a one-line form.',
    examples: [
      <div>
        
      </div>,
      <form>
        <div>
          
            From
          
          
            To
          
          
            Depart
          
          
            Return</div></form>
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
,
      
        {longMessage}
      ,
      
        {longMessage}
      ,
      
        {longMessage}
      ,
    ],
  },
  {
    id: 'dismissable',
    title: 'Dismissable',
    blurb: [
      
        Banner alerts can be configured to include a close icon so that the user
        can dismiss them.
      ,
    ],
    examples: [
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
type: ALERT_TYPES.NEUTRAL,
      },
      {
        show: true,
        message: 'Successful alert with dismiss option.',
        type: ALERT_TYPES.SUCCESS,
      },
      {
        show: true,
        message: 'Warn alert with dismiss option.',
        type: ALERT_TYPES.WARN,
      },
      {
        show: true,
        message: 'Error alert with dismiss option.',
        type: ALERT_TYPES.ERROR,
      },
    ];

    this.state = {
      bannerAlerts: JSON.parse(JSON.stringify(this.bannerAlerts)),
      dirty: false,
    };
  }
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
,
    ],
  },
  {
    id: 'expandable',
    title: 'Expandable',
    blurb: [
      
        They can be configured to display further information to the user in the
        form of an expandable panel.
      ,
    ],
    examples: [
      
        {longMessage}
      ,
      
        {longMessage}
      ,
      
        {longMessage}
      ,
github Skyscanner / backpack / packages / bpk-docs / src / pages / WebBannerAlertsPage / BannerAlertsPage.js View on Github external
constructor() {
    super();

    this.bannerAlerts = [
      {
        show: true,
        message: 'Neutral alert with dismiss option.',
        type: ALERT_TYPES.NEUTRAL,
      },
      {
        show: true,
        message: 'Successful alert with dismiss option.',
        type: ALERT_TYPES.SUCCESS,
      },
      {
        show: true,
        message: 'Warn alert with dismiss option.',
        type: ALERT_TYPES.WARN,
      },
      {
        show: true,
        message: 'Error alert with dismiss option.',
        type: ALERT_TYPES.ERROR,
      },

bpk-component-banner-alert

Backpack banner alert component.

Apache-2.0
Latest version published 2 years ago

Package Health Score

70 / 100
Full package analysis

Similar packages