import React,{Component} from 'react'
import {Table as Table1,notification ,Button as Button1} from 'antd'

// export function Table(props)
// {
//     return <Table1 {...props} />
// }
// export function Button(props)
// {
//     return <Button1 {...props}/>
// }

export class Notification{
    static  message(options)
    {
        notification.info(options)
    }
    static  error(options)
    {
        notification.error(options)
    }
    static  success(options)
    {
        notification.success(options)
    }
}

pagination_config = {
    size: "small",
    showSizeChanger: true,
    showQuickJumper: true,
    pageSize: 10,
    pageSizeOptions: ['5', '10', '15'],
}

export class Table extends Component{

    rowClass=(record, index)=>{
        if(index %2)
        {
            return "tableEvenStyle"
        }
        return "tableOddStyle"

    }

    render(){
        const props = this.props
        return <Table1 size="middle" {...props} rowClassName={this.rowClass}/>
    }
}
export class Button extends Component{
    render()
    {
        const props = this.props
        return <Button1 size="small" {...props} />
    }
}