1.0.5 • Published 5 years ago

comp-button v1.0.5

Weekly downloads
-
License
MIT
Repository
-
Last release
5 years ago

comp-button

API

属性说明类型默认值
extendType拓展的按钮类型,支持 successdangerwarninginfosecondaryString

其他参数与 Antd Button 一致

Example

import React from 'react';
import { render } from 'react-dom';
import { Icon } from 'antd';
import CompButton from 'comp-button';

render(
  <div style={{padding: 40}}>
    <h2>Antd Normal</h2>
    <CompButton type="primary" style={{marginRight: 20}}>primary</CompButton>
    <CompButton type="default" style={{marginRight: 20}}>default</CompButton>
    <CompButton type="dashed" style={{marginRight: 20}}>dashed</CompButton>
    <CompButton type="danger" style={{marginRight: 20}}>danger</CompButton>
    <br />
    <br />
    <h2>Custom Extend</h2>
    <CompButton extendType="success" style={{marginRight: 20}}><Icon type="check" />success</CompButton>
    <CompButton extendType="danger" style={{marginRight: 20}}>danger</CompButton>
    <CompButton extendType="warning" style={{marginRight: 20}}>warning</CompButton>
    <CompButton extendType="info" style={{marginRight: 20}}>info</CompButton>
    <CompButton extendType="secondary" style={{marginRight: 20}}>secondary</CompButton>
  </div>,
  document.getElementById('app')
);

demo

Development

$ npm run start

Build

$ npm run build

Publish

$ npm publish
1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago