1.0.2 • Published 3 years ago
@lena-codes/smartbanner-react v1.0.2
smartbanner-react
React component library implementing the iOS specific smart banner for all platforms
Light Theme

Dark Theme

Install
npm install --save @lena-codes/smartbanner-reactor
yarn add @lena-codes/smartbanner-reactUsage
import { SmartBanner } from '@lena-codes/smartbanner-react'
<SmartBanner
src='enter-your-icon-here.png'
title='MyApp'
author='lena.codes'
description='GET - On the Play Store'
buttonLink='https://lena.codes'
buttonText='View'
onClose={() => alert('pressed the close button!')}
/>| Parameter | Type | Description |
|---|---|---|
| src | string | required Image source |
| title | string | required First line of text |
| author | string | required Second line of text |
| description | string | required Third line of text |
| buttonText | string | required Button text |
| buttonLink | string | required Button link |
| onClose | ( ) => void | optional Function implementing the close button; if not set button is hidden |
| theme | 'light' | 'dark' | optional Predefined color theme, defaults to 'light' if not set |
| background | string | optional sets the background css value; overwrites theme value |
| closeIconColor | string | optional sets the close icon color; overwrites theme value |
| textColor | string | optional sets the text color; overwrites theme value |
| titleColor | string | optional sets the title color; overwrites theme value |
| buttonColor | string | optional sets the link button color; overwrites theme value |
Check it out
Build the project
npm run buildRun demo locally
npm startLicense
MIT © lena-codes