jrs-react 1.1.12 → 1.1.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jrs-react",
3
- "version": "1.1.12",
3
+ "version": "1.1.15",
4
4
  "description": "",
5
5
  "main": "build/index.js",
6
6
  "module": "build/index.es.js",
@@ -2,21 +2,22 @@ import React from "react";
2
2
  import JRSubmit from "../JRSubmit";
3
3
  import { StyledJRFrame } from "./StyledJRFrame";
4
4
 
5
- const FreeType=({tag:Tag,config,me,className})=>{
6
- if(typeof config==='function'){
7
- let style
8
- const setStyle=function(_style){
9
- style=_style
10
- }
11
- const content=config.bind(me)({setStyle})
12
- return <Tag className={className} style={style}>{content}</Tag>
13
- }
14
- }
5
+ // const FreeType=({tag:Tag,config,me,className})=>{
6
+ // if(typeof config==='function'){
7
+ // let style
8
+ // const setStyle=function(_style){
9
+ // style=_style
10
+ // }
11
+ // const content=config.bind(me)({setStyle})
12
+ // return <Tag className={className} style={style}>{content}</Tag>
13
+ // }
14
+ // }
15
15
 
16
16
  export default class JRFrame extends JRSubmit {
17
17
  renderer(){
18
18
  return <StyledJRFrame style={this.props.style} className={`${this.props.className} jr-frame`} >
19
- <FreeType tag='div' config={this.props.start} me={this} className={'start'}/>
19
+ {this.renderMe()}
20
+ {/* <FreeType tag='div' config={this.props.start} me={this} className={'start'}/>
20
21
  <main>
21
22
  <FreeType tag='header' config={this.props.top} me={this}/>
22
23
  <main>
@@ -26,7 +27,7 @@ export default class JRFrame extends JRSubmit {
26
27
  </main>
27
28
  <FreeType tag='footer' config={this.props.bottom} me={this}/>
28
29
  </main>
29
- <FreeType tag='div' config={this.props.end} me={this} className={'end'}/>
30
+ <FreeType tag='div' config={this.props.end} me={this} className={'end'}/> */}
30
31
  </StyledJRFrame>
31
32
  }
32
33
 
@@ -1,8 +1,10 @@
1
- import React from "react";
1
+ import { po } from "../JRUtils";
2
2
  import { TFoot, THead } from "./THead";
3
3
  import { TBodies } from "./TBodies";
4
4
  import { StyledJRTable } from "./StyledJRTable";
5
5
  import JRFrame from "../JRFrame/JRFrame";
6
+ import { Button, Checkbox } from "antd";
7
+ import React from "react";
6
8
 
7
9
 
8
10
  const getMapObject=(map,names)=>{
@@ -42,7 +44,7 @@ export default class JRTable extends JRFrame {
42
44
  checkableColumn(props){
43
45
  return {//方法1
44
46
  render({value,onChange}){
45
- return <checkbox checked={value} onChange={(e)=>{onChange(e.target.checked)}}/>
47
+ return <Checkbox checked={value} onChange={(e)=>{onChange(e.target.checked)}}/>
46
48
  }
47
49
  ,align:'center'
48
50
  ,name:'checked'
@@ -67,12 +69,12 @@ export default class JRTable extends JRFrame {
67
69
  deletableColumn({name='deletable',sendValue,sendName,valueName,...props}){
68
70
  return {
69
71
  render({value,onChange}){
70
- return <checkbox checked={value} onChange={(e)=>{onChange(e.target.checked)}}/>
72
+ return <Checkbox checked={value} onChange={(e)=>{onChange(e.target.checked)}}/>
71
73
  }
72
74
  ,align:'center'
73
75
  ,name
74
76
  ,label(){
75
- return <button
77
+ return <Button
76
78
  onClick={()=>{
77
79
  const value=this.props.delete.value
78
80
  ?? this.getDataSource()?.filter(record=>record[name]).map(record=>sendValue?record[sendValue]:record)
@@ -86,7 +88,7 @@ export default class JRTable extends JRFrame {
86
88
  ,...props
87
89
  })
88
90
  }}
89
- >刪除</button>
91
+ >刪除</Button>
90
92
  }
91
93
  ,...props
92
94
  }
package/src/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import JRSubmit from './components/JRSubmit'
2
2
  import JRFrame from './components/JRFrame/JRFrame'
3
- import JRTable from './components/JRTable/JRTable'
3
+ // import JRTable from './components/JRTable/JRTable'
4
4
  import JRTest,{JRTestReact} from './components/JRTest'
5
5
  export {
6
6
  JRTest,JRTestReact
7
- ,JRSubmit,JRFrame,JRTable
7
+ ,JRSubmit,JRFrame//,JRTable
8
8
  }