saltovo-compents
TypeScript icon, indicating that this package has built-in type declarations

1.0.1-beta.13 • Public • Published

saltovo-compents

sedt react 组件库 Made by saltovo

NPM JavaScript Style Guide

Install

npm install --save saltovo-compents or yarn add  saltovo-compents

Formtable

专家库系列组件专用 table 和 input 的结合

import React, { Component } from 'react';

import { FormTable } from 'saltovo-compents';

class Example extends Component {
  render() {
    return (
      <FormTable
        title={'社会兼职'}
        colunmns={SocialPosition}
        cardtitle="社会兼职(学会、协会、兼职教授)"
        data={formData.SocialpositionList}
        title="近三年社会兼职"
      />
    );
  }
}

layoutmixrightcontent

antd-pro 退出使用提示,

import { layoutmixrightcontent } from 'saltovo-compents';
export default () => {
  let UserName = 'saltovo';
  let loginout = () => {
    //退出登录的操作
  };
  return <LayoutMixRightContent loginout={loginout} UserName={UserName} />;
};

Saltable

在 antd table 的基础上增加了列设置与 toolBarRender,支持 antd table 的所有参数

import { Saltable } from 'saltovo-compents';
import 'saltovo-compents/dist/index.css';
export default () => {
  const columns = [
    {
      title: '姓名',
      dataIndex: 'Name',
      width: 80,
      align: 'center',
      defaultchecked: true,
    },
    {
      title: '职级',
      dataIndex: 'Rank',
      align: 'center',
      width: 100,
    },
  ];

  return (
    <Saltable
      /*
        toolBarRender支持function,array
        columns设置默认展示的列 defaultchecked: true,
        onColumnsStateChange输出当前的columns
        */
        onColumnsStateChange={(ColumnsSelceted) => {
          console.log(ColumnsSelceted)
        }}
      toolBarRender={[</div>]}
      columns={columns}
    />
  );
};

License

MIT ©

Package Sidebar

Install

npm i saltovo-compents

Weekly Downloads

3

Version

1.0.1-beta.13

License

MIT

Unpacked Size

518 kB

Total Files

16

Last publish

Collaborators

  • saltovo