3.0.1 • Published 9 years ago

apeman-react-notice v3.0.1

Weekly downloads
3
License
MIT
Repository
github
Last release
9 years ago

apeman-react-notice

Build Status Code Climate Code Coverage npm Version JS Standard

apeman react package for notice components

Installation

$ npm install apeman-react-notice --save

Demo

Live demo is hosted on GitHub Pages.

Usage

'use strict'

import React from 'react'
import {ApNotice, ApNoticeStyle} from 'apeman-react-notice'

const ExampleComponent = React.createClass({
  render () {
    const s = this
    return (
      <div>
        <ApNoticeStyle />
        <ApNotice>
          <ApNoticeItem text="Are you sure to do that?"
                        actions={
                        {
                            'YES': s._handleYes  ,
                            'NO':s._handleNo
                        }
                    }/>
        </ApNotice>
      </div>
    )
  },

  _handleYes() {
    /* ... */
  },

  _handleNo() {
    /* ... */
  }
})

Components

ApNoticeItem

Props

NameTypeDefaultDescription
textstringnullItem text
actionsobjectnullAction button text and handlers
hiddenboolfalseHide component
levelenum'DEFAULT'Information level

ApNoticeStyle

Props

NameTypeDefaultDescription
styleobject{}
highlightColorstringApStyle.DEFAULT_HIGHLIGHT_COLOR
backgroundColorApStyle.DEFAULT_BACKGROUND_COLOR
normalColorApStyle.NORMAL_COLOR
infoColorApStyle.INFO_COLOR
warnColorApStyle.WARN_COLOR
errorColorApStyle.ERROR_COLOR

ApNotice

Props

NameTypeDefaultDescription
spinningboolfalseShow spinner
spinnerstringApSpinner.DEFAULT_THEMESpinner theme

License

This software is released under the MIT License.

Links

3.0.1

9 years ago

3.0.0

9 years ago

2.0.6

9 years ago

2.0.5

9 years ago

2.0.4

9 years ago

2.0.3

9 years ago

2.0.2

9 years ago

2.0.1

9 years ago

2.0.0

9 years ago

1.1.4

9 years ago

1.1.3

9 years ago

1.1.2

9 years ago

1.1.1

9 years ago

1.1.0

9 years ago

1.0.8

9 years ago

1.0.7

9 years ago

1.0.6

9 years ago

1.0.5

9 years ago

1.0.4

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago