1.0.1 • Published 3 years ago

anchor-components-modal-fusion v1.0.1

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

anchor-components-modal-fusion

anchoremc component libs modal

NPM JavaScript Style Guide

Install

npm install --save anchor-components-modal-fusion

Usage

import React, { Component } from 'react'
import { ModalComponent } from 'anchor-components-modal-fusion'
import { Button } from '@alifd/next'

export default class App extends Component {
  handleButtonOnClick = () => {
    this.modalComponent.openModal()
  }
  render() {
    return (
      <div style={{ padding: 15 }}>
        <Button type={'primary'} onClick={this.handleButtonOnClick}>
          打开Modal
        </Button>
        <ModalComponent
          ref={(node) => (this.modalComponent = node)}
          title='demo'
          width={'460'}
          height={'320'}
        >
          <div style={{ textAlign: 'center' }}>我是弹窗内容</div>
        </ModalComponent>
      </div>
    )
  }
}

License

MIT © https://github.com/devfpy

1.0.1

3 years ago

1.0.0

3 years ago