@comparaonline/ui-offer-banner

This component will render an informative banner for the app

Usage no npm install needed!

<script type="module">
  import comparaonlineUiOfferBanner from 'https://cdn.skypack.dev/@comparaonline/ui-offer-banner';
</script>

README

ui-offer-banner

This component will render an informative banner for the app

Installation

yarn add @comparaonline/ui-offer-banner

Usage

import Banner from '@comparaonline/ui-offer-banner';

class MyView extends React.Component {
  render() {
    return (
      <Banner>
        <Grid container>
          <Grid item>
            <img src="http://example.com/image.jpg" />
          </Grid>

          <Grid item>This is the message I want to show you</Grid>
        </Grid>
      </Banner>
    );
  }
}
Prop Name Description Default Value Expected Type Value Required
open boolean flag to tell to component if is open or not undefined (false) boolean false
onClose a function that will be invoked when X icon is clicked undefined () => void false
children The content to shown into the banner undefined ReactNode false

 Happy coding :sunglasses: